airweave-sdk 0.8.64__py3-none-any.whl → 0.8.66__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.
- airweave/__init__.py +44 -38
- airweave/client.py +19 -16
- airweave/collections/__init__.py +3 -6
- airweave/collections/client.py +273 -113
- airweave/collections/raw_client.py +633 -94
- airweave/collections/types/__init__.py +2 -4
- airweave/core/client_wrapper.py +4 -30
- airweave/errors/__init__.py +10 -2
- airweave/errors/conflict_error.py +11 -0
- airweave/errors/not_found_error.py +11 -0
- airweave/errors/too_many_requests_error.py +11 -0
- airweave/errors/unprocessable_entity_error.py +1 -2
- airweave/{types/message_status.py → events/__init__.py} +2 -1
- airweave/events/client.py +919 -0
- airweave/events/raw_client.py +1435 -0
- airweave/source_connections/client.py +210 -162
- airweave/source_connections/raw_client.py +574 -137
- airweave/sources/client.py +42 -18
- airweave/sources/raw_client.py +118 -17
- airweave/types/__init__.py +33 -33
- airweave/types/{create_subscription_request.py → conflict_error_response.py} +9 -6
- airweave/types/delivery_attempt.py +61 -0
- airweave/types/event_message.py +55 -0
- airweave/types/event_message_with_attempts.py +59 -0
- airweave/types/{endpoint_secret_out.py → not_found_error_response.py} +9 -2
- airweave/types/{subscription_with_attempts_out.py → rate_limit_error_response.py} +9 -6
- airweave/types/recovery_task.py +35 -0
- airweave/types/search_request.py +13 -10
- airweave/types/search_response.py +6 -3
- airweave/types/source_connection.py +73 -18
- airweave/types/source_connection_job.py +65 -15
- airweave/types/source_connection_list_item.py +45 -10
- airweave/types/sync_event_payload.py +72 -0
- airweave/types/{patch_subscription_request.py → validation_error_detail.py} +16 -5
- airweave/types/validation_error_response.py +30 -0
- airweave/types/webhook_subscription.py +68 -0
- {airweave_sdk-0.8.64.dist-info → airweave_sdk-0.8.66.dist-info}/METADATA +1 -5
- {airweave_sdk-0.8.64.dist-info → airweave_sdk-0.8.66.dist-info}/RECORD +39 -34
- airweave/collections/types/search_collections_readable_id_search_post_response.py +0 -8
- airweave/types/collection_update.py +0 -35
- airweave/types/endpoint_out.py +0 -35
- airweave/types/message_attempt_out.py +0 -37
- airweave/types/message_attempt_trigger_type.py +0 -3
- airweave/types/message_out.py +0 -29
- airweave/types/message_status_text.py +0 -5
- {airweave_sdk-0.8.64.dist-info → airweave_sdk-0.8.66.dist-info}/WHEEL +0 -0
airweave/sources/client.py
CHANGED
|
@@ -25,10 +25,17 @@ class SourcesClient:
|
|
|
25
25
|
|
|
26
26
|
def list(self, *, request_options: typing.Optional[RequestOptions] = None) -> typing.List[Source]:
|
|
27
27
|
"""
|
|
28
|
-
|
|
28
|
+
Retrieve all available data source connectors.
|
|
29
29
|
|
|
30
|
-
|
|
31
|
-
|
|
30
|
+
Returns the complete catalog of source types that Airweave can connect to,
|
|
31
|
+
including their authentication methods, configuration requirements, and
|
|
32
|
+
supported features. Use this endpoint to discover which integrations are
|
|
33
|
+
available for your organization.
|
|
34
|
+
|
|
35
|
+
Each source includes:
|
|
36
|
+
- **Authentication methods**: How to connect (OAuth, API key, etc.)
|
|
37
|
+
- **Configuration schemas**: What settings are required or optional
|
|
38
|
+
- **Supported auth providers**: Pre-configured OAuth providers available
|
|
32
39
|
|
|
33
40
|
Parameters
|
|
34
41
|
----------
|
|
@@ -45,8 +52,6 @@ class SourcesClient:
|
|
|
45
52
|
from airweave import AirweaveSDK
|
|
46
53
|
|
|
47
54
|
client = AirweaveSDK(
|
|
48
|
-
framework_name="YOUR_FRAMEWORK_NAME",
|
|
49
|
-
framework_version="YOUR_FRAMEWORK_VERSION",
|
|
50
55
|
api_key="YOUR_API_KEY",
|
|
51
56
|
)
|
|
52
57
|
client.sources.list()
|
|
@@ -56,7 +61,16 @@ class SourcesClient:
|
|
|
56
61
|
|
|
57
62
|
def get(self, short_name: str, *, request_options: typing.Optional[RequestOptions] = None) -> Source:
|
|
58
63
|
"""
|
|
59
|
-
|
|
64
|
+
Retrieve detailed information about a specific data source connector.
|
|
65
|
+
|
|
66
|
+
Returns the complete configuration for a source type, including:
|
|
67
|
+
|
|
68
|
+
- **Authentication fields**: Schema for credentials required to connect
|
|
69
|
+
- **Configuration fields**: Schema for optional settings and customization
|
|
70
|
+
- **Supported auth providers**: Pre-configured OAuth providers available for this source
|
|
71
|
+
|
|
72
|
+
Use this endpoint before creating a source connection to understand what
|
|
73
|
+
authentication and configuration values are required.
|
|
60
74
|
|
|
61
75
|
Parameters
|
|
62
76
|
----------
|
|
@@ -76,12 +90,10 @@ class SourcesClient:
|
|
|
76
90
|
from airweave import AirweaveSDK
|
|
77
91
|
|
|
78
92
|
client = AirweaveSDK(
|
|
79
|
-
framework_name="YOUR_FRAMEWORK_NAME",
|
|
80
|
-
framework_version="YOUR_FRAMEWORK_VERSION",
|
|
81
93
|
api_key="YOUR_API_KEY",
|
|
82
94
|
)
|
|
83
95
|
client.sources.get(
|
|
84
|
-
short_name="
|
|
96
|
+
short_name="github",
|
|
85
97
|
)
|
|
86
98
|
"""
|
|
87
99
|
_response = self._raw_client.get(short_name, request_options=request_options)
|
|
@@ -105,10 +117,17 @@ class AsyncSourcesClient:
|
|
|
105
117
|
|
|
106
118
|
async def list(self, *, request_options: typing.Optional[RequestOptions] = None) -> typing.List[Source]:
|
|
107
119
|
"""
|
|
108
|
-
|
|
120
|
+
Retrieve all available data source connectors.
|
|
109
121
|
|
|
110
|
-
|
|
111
|
-
|
|
122
|
+
Returns the complete catalog of source types that Airweave can connect to,
|
|
123
|
+
including their authentication methods, configuration requirements, and
|
|
124
|
+
supported features. Use this endpoint to discover which integrations are
|
|
125
|
+
available for your organization.
|
|
126
|
+
|
|
127
|
+
Each source includes:
|
|
128
|
+
- **Authentication methods**: How to connect (OAuth, API key, etc.)
|
|
129
|
+
- **Configuration schemas**: What settings are required or optional
|
|
130
|
+
- **Supported auth providers**: Pre-configured OAuth providers available
|
|
112
131
|
|
|
113
132
|
Parameters
|
|
114
133
|
----------
|
|
@@ -127,8 +146,6 @@ class AsyncSourcesClient:
|
|
|
127
146
|
from airweave import AsyncAirweaveSDK
|
|
128
147
|
|
|
129
148
|
client = AsyncAirweaveSDK(
|
|
130
|
-
framework_name="YOUR_FRAMEWORK_NAME",
|
|
131
|
-
framework_version="YOUR_FRAMEWORK_VERSION",
|
|
132
149
|
api_key="YOUR_API_KEY",
|
|
133
150
|
)
|
|
134
151
|
|
|
@@ -144,7 +161,16 @@ class AsyncSourcesClient:
|
|
|
144
161
|
|
|
145
162
|
async def get(self, short_name: str, *, request_options: typing.Optional[RequestOptions] = None) -> Source:
|
|
146
163
|
"""
|
|
147
|
-
|
|
164
|
+
Retrieve detailed information about a specific data source connector.
|
|
165
|
+
|
|
166
|
+
Returns the complete configuration for a source type, including:
|
|
167
|
+
|
|
168
|
+
- **Authentication fields**: Schema for credentials required to connect
|
|
169
|
+
- **Configuration fields**: Schema for optional settings and customization
|
|
170
|
+
- **Supported auth providers**: Pre-configured OAuth providers available for this source
|
|
171
|
+
|
|
172
|
+
Use this endpoint before creating a source connection to understand what
|
|
173
|
+
authentication and configuration values are required.
|
|
148
174
|
|
|
149
175
|
Parameters
|
|
150
176
|
----------
|
|
@@ -166,15 +192,13 @@ class AsyncSourcesClient:
|
|
|
166
192
|
from airweave import AsyncAirweaveSDK
|
|
167
193
|
|
|
168
194
|
client = AsyncAirweaveSDK(
|
|
169
|
-
framework_name="YOUR_FRAMEWORK_NAME",
|
|
170
|
-
framework_version="YOUR_FRAMEWORK_VERSION",
|
|
171
195
|
api_key="YOUR_API_KEY",
|
|
172
196
|
)
|
|
173
197
|
|
|
174
198
|
|
|
175
199
|
async def main() -> None:
|
|
176
200
|
await client.sources.get(
|
|
177
|
-
short_name="
|
|
201
|
+
short_name="github",
|
|
178
202
|
)
|
|
179
203
|
|
|
180
204
|
|
airweave/sources/raw_client.py
CHANGED
|
@@ -9,8 +9,11 @@ from ..core.http_response import AsyncHttpResponse, HttpResponse
|
|
|
9
9
|
from ..core.jsonable_encoder import jsonable_encoder
|
|
10
10
|
from ..core.pydantic_utilities import parse_obj_as
|
|
11
11
|
from ..core.request_options import RequestOptions
|
|
12
|
+
from ..errors.not_found_error import NotFoundError
|
|
13
|
+
from ..errors.too_many_requests_error import TooManyRequestsError
|
|
12
14
|
from ..errors.unprocessable_entity_error import UnprocessableEntityError
|
|
13
|
-
from ..types.
|
|
15
|
+
from ..types.not_found_error_response import NotFoundErrorResponse
|
|
16
|
+
from ..types.rate_limit_error_response import RateLimitErrorResponse
|
|
14
17
|
from ..types.source import Source
|
|
15
18
|
|
|
16
19
|
|
|
@@ -20,10 +23,17 @@ class RawSourcesClient:
|
|
|
20
23
|
|
|
21
24
|
def list(self, *, request_options: typing.Optional[RequestOptions] = None) -> HttpResponse[typing.List[Source]]:
|
|
22
25
|
"""
|
|
23
|
-
|
|
26
|
+
Retrieve all available data source connectors.
|
|
24
27
|
|
|
25
|
-
|
|
26
|
-
|
|
28
|
+
Returns the complete catalog of source types that Airweave can connect to,
|
|
29
|
+
including their authentication methods, configuration requirements, and
|
|
30
|
+
supported features. Use this endpoint to discover which integrations are
|
|
31
|
+
available for your organization.
|
|
32
|
+
|
|
33
|
+
Each source includes:
|
|
34
|
+
- **Authentication methods**: How to connect (OAuth, API key, etc.)
|
|
35
|
+
- **Configuration schemas**: What settings are required or optional
|
|
36
|
+
- **Supported auth providers**: Pre-configured OAuth providers available
|
|
27
37
|
|
|
28
38
|
Parameters
|
|
29
39
|
----------
|
|
@@ -54,9 +64,20 @@ class RawSourcesClient:
|
|
|
54
64
|
raise UnprocessableEntityError(
|
|
55
65
|
headers=dict(_response.headers),
|
|
56
66
|
body=typing.cast(
|
|
57
|
-
|
|
67
|
+
typing.Optional[typing.Any],
|
|
58
68
|
parse_obj_as(
|
|
59
|
-
type_=
|
|
69
|
+
type_=typing.Optional[typing.Any], # type: ignore
|
|
70
|
+
object_=_response.json(),
|
|
71
|
+
),
|
|
72
|
+
),
|
|
73
|
+
)
|
|
74
|
+
if _response.status_code == 429:
|
|
75
|
+
raise TooManyRequestsError(
|
|
76
|
+
headers=dict(_response.headers),
|
|
77
|
+
body=typing.cast(
|
|
78
|
+
RateLimitErrorResponse,
|
|
79
|
+
parse_obj_as(
|
|
80
|
+
type_=RateLimitErrorResponse, # type: ignore
|
|
60
81
|
object_=_response.json(),
|
|
61
82
|
),
|
|
62
83
|
),
|
|
@@ -68,7 +89,16 @@ class RawSourcesClient:
|
|
|
68
89
|
|
|
69
90
|
def get(self, short_name: str, *, request_options: typing.Optional[RequestOptions] = None) -> HttpResponse[Source]:
|
|
70
91
|
"""
|
|
71
|
-
|
|
92
|
+
Retrieve detailed information about a specific data source connector.
|
|
93
|
+
|
|
94
|
+
Returns the complete configuration for a source type, including:
|
|
95
|
+
|
|
96
|
+
- **Authentication fields**: Schema for credentials required to connect
|
|
97
|
+
- **Configuration fields**: Schema for optional settings and customization
|
|
98
|
+
- **Supported auth providers**: Pre-configured OAuth providers available for this source
|
|
99
|
+
|
|
100
|
+
Use this endpoint before creating a source connection to understand what
|
|
101
|
+
authentication and configuration values are required.
|
|
72
102
|
|
|
73
103
|
Parameters
|
|
74
104
|
----------
|
|
@@ -98,13 +128,35 @@ class RawSourcesClient:
|
|
|
98
128
|
),
|
|
99
129
|
)
|
|
100
130
|
return HttpResponse(response=_response, data=_data)
|
|
131
|
+
if _response.status_code == 404:
|
|
132
|
+
raise NotFoundError(
|
|
133
|
+
headers=dict(_response.headers),
|
|
134
|
+
body=typing.cast(
|
|
135
|
+
NotFoundErrorResponse,
|
|
136
|
+
parse_obj_as(
|
|
137
|
+
type_=NotFoundErrorResponse, # type: ignore
|
|
138
|
+
object_=_response.json(),
|
|
139
|
+
),
|
|
140
|
+
),
|
|
141
|
+
)
|
|
101
142
|
if _response.status_code == 422:
|
|
102
143
|
raise UnprocessableEntityError(
|
|
103
144
|
headers=dict(_response.headers),
|
|
104
145
|
body=typing.cast(
|
|
105
|
-
|
|
146
|
+
typing.Optional[typing.Any],
|
|
147
|
+
parse_obj_as(
|
|
148
|
+
type_=typing.Optional[typing.Any], # type: ignore
|
|
149
|
+
object_=_response.json(),
|
|
150
|
+
),
|
|
151
|
+
),
|
|
152
|
+
)
|
|
153
|
+
if _response.status_code == 429:
|
|
154
|
+
raise TooManyRequestsError(
|
|
155
|
+
headers=dict(_response.headers),
|
|
156
|
+
body=typing.cast(
|
|
157
|
+
RateLimitErrorResponse,
|
|
106
158
|
parse_obj_as(
|
|
107
|
-
type_=
|
|
159
|
+
type_=RateLimitErrorResponse, # type: ignore
|
|
108
160
|
object_=_response.json(),
|
|
109
161
|
),
|
|
110
162
|
),
|
|
@@ -123,10 +175,17 @@ class AsyncRawSourcesClient:
|
|
|
123
175
|
self, *, request_options: typing.Optional[RequestOptions] = None
|
|
124
176
|
) -> AsyncHttpResponse[typing.List[Source]]:
|
|
125
177
|
"""
|
|
126
|
-
|
|
178
|
+
Retrieve all available data source connectors.
|
|
127
179
|
|
|
128
|
-
|
|
129
|
-
|
|
180
|
+
Returns the complete catalog of source types that Airweave can connect to,
|
|
181
|
+
including their authentication methods, configuration requirements, and
|
|
182
|
+
supported features. Use this endpoint to discover which integrations are
|
|
183
|
+
available for your organization.
|
|
184
|
+
|
|
185
|
+
Each source includes:
|
|
186
|
+
- **Authentication methods**: How to connect (OAuth, API key, etc.)
|
|
187
|
+
- **Configuration schemas**: What settings are required or optional
|
|
188
|
+
- **Supported auth providers**: Pre-configured OAuth providers available
|
|
130
189
|
|
|
131
190
|
Parameters
|
|
132
191
|
----------
|
|
@@ -157,9 +216,20 @@ class AsyncRawSourcesClient:
|
|
|
157
216
|
raise UnprocessableEntityError(
|
|
158
217
|
headers=dict(_response.headers),
|
|
159
218
|
body=typing.cast(
|
|
160
|
-
|
|
219
|
+
typing.Optional[typing.Any],
|
|
161
220
|
parse_obj_as(
|
|
162
|
-
type_=
|
|
221
|
+
type_=typing.Optional[typing.Any], # type: ignore
|
|
222
|
+
object_=_response.json(),
|
|
223
|
+
),
|
|
224
|
+
),
|
|
225
|
+
)
|
|
226
|
+
if _response.status_code == 429:
|
|
227
|
+
raise TooManyRequestsError(
|
|
228
|
+
headers=dict(_response.headers),
|
|
229
|
+
body=typing.cast(
|
|
230
|
+
RateLimitErrorResponse,
|
|
231
|
+
parse_obj_as(
|
|
232
|
+
type_=RateLimitErrorResponse, # type: ignore
|
|
163
233
|
object_=_response.json(),
|
|
164
234
|
),
|
|
165
235
|
),
|
|
@@ -173,7 +243,16 @@ class AsyncRawSourcesClient:
|
|
|
173
243
|
self, short_name: str, *, request_options: typing.Optional[RequestOptions] = None
|
|
174
244
|
) -> AsyncHttpResponse[Source]:
|
|
175
245
|
"""
|
|
176
|
-
|
|
246
|
+
Retrieve detailed information about a specific data source connector.
|
|
247
|
+
|
|
248
|
+
Returns the complete configuration for a source type, including:
|
|
249
|
+
|
|
250
|
+
- **Authentication fields**: Schema for credentials required to connect
|
|
251
|
+
- **Configuration fields**: Schema for optional settings and customization
|
|
252
|
+
- **Supported auth providers**: Pre-configured OAuth providers available for this source
|
|
253
|
+
|
|
254
|
+
Use this endpoint before creating a source connection to understand what
|
|
255
|
+
authentication and configuration values are required.
|
|
177
256
|
|
|
178
257
|
Parameters
|
|
179
258
|
----------
|
|
@@ -203,13 +282,35 @@ class AsyncRawSourcesClient:
|
|
|
203
282
|
),
|
|
204
283
|
)
|
|
205
284
|
return AsyncHttpResponse(response=_response, data=_data)
|
|
285
|
+
if _response.status_code == 404:
|
|
286
|
+
raise NotFoundError(
|
|
287
|
+
headers=dict(_response.headers),
|
|
288
|
+
body=typing.cast(
|
|
289
|
+
NotFoundErrorResponse,
|
|
290
|
+
parse_obj_as(
|
|
291
|
+
type_=NotFoundErrorResponse, # type: ignore
|
|
292
|
+
object_=_response.json(),
|
|
293
|
+
),
|
|
294
|
+
),
|
|
295
|
+
)
|
|
206
296
|
if _response.status_code == 422:
|
|
207
297
|
raise UnprocessableEntityError(
|
|
208
298
|
headers=dict(_response.headers),
|
|
209
299
|
body=typing.cast(
|
|
210
|
-
|
|
300
|
+
typing.Optional[typing.Any],
|
|
301
|
+
parse_obj_as(
|
|
302
|
+
type_=typing.Optional[typing.Any], # type: ignore
|
|
303
|
+
object_=_response.json(),
|
|
304
|
+
),
|
|
305
|
+
),
|
|
306
|
+
)
|
|
307
|
+
if _response.status_code == 429:
|
|
308
|
+
raise TooManyRequestsError(
|
|
309
|
+
headers=dict(_response.headers),
|
|
310
|
+
body=typing.cast(
|
|
311
|
+
RateLimitErrorResponse,
|
|
211
312
|
parse_obj_as(
|
|
212
|
-
type_=
|
|
313
|
+
type_=RateLimitErrorResponse, # type: ignore
|
|
213
314
|
object_=_response.json(),
|
|
214
315
|
),
|
|
215
316
|
),
|
airweave/types/__init__.py
CHANGED
|
@@ -36,23 +36,21 @@ if typing.TYPE_CHECKING:
|
|
|
36
36
|
from .checkout_session_response import CheckoutSessionResponse
|
|
37
37
|
from .collection import Collection
|
|
38
38
|
from .collection_status import CollectionStatus
|
|
39
|
-
from .collection_update import CollectionUpdate
|
|
40
39
|
from .config_field import ConfigField
|
|
41
40
|
from .config_values import ConfigValues
|
|
41
|
+
from .conflict_error_response import ConflictErrorResponse
|
|
42
42
|
from .connection import Connection
|
|
43
43
|
from .connection_status import ConnectionStatus
|
|
44
|
-
from .create_subscription_request import CreateSubscriptionRequest
|
|
45
44
|
from .cursor_config import CursorConfig
|
|
46
45
|
from .customer_portal_request import CustomerPortalRequest
|
|
47
46
|
from .customer_portal_response import CustomerPortalResponse
|
|
47
|
+
from .delivery_attempt import DeliveryAttempt
|
|
48
48
|
from .destination import Destination
|
|
49
49
|
from .destination_config import DestinationConfig
|
|
50
50
|
from .destination_with_authentication_fields import DestinationWithAuthenticationFields
|
|
51
51
|
from .direct_authentication import DirectAuthentication
|
|
52
52
|
from .embedding_model import EmbeddingModel
|
|
53
53
|
from .embedding_model_with_authentication_fields import EmbeddingModelWithAuthenticationFields
|
|
54
|
-
from .endpoint_out import EndpointOut
|
|
55
|
-
from .endpoint_secret_out import EndpointSecretOut
|
|
56
54
|
from .entity_count import EntityCount
|
|
57
55
|
from .entity_count_with_definition import EntityCountWithDefinition
|
|
58
56
|
from .entity_definition import EntityDefinition
|
|
@@ -62,6 +60,8 @@ if typing.TYPE_CHECKING:
|
|
|
62
60
|
from .entity_summary import EntitySummary
|
|
63
61
|
from .entity_type import EntityType
|
|
64
62
|
from .entity_type_stats import EntityTypeStats
|
|
63
|
+
from .event_message import EventMessage
|
|
64
|
+
from .event_message_with_attempts import EventMessageWithAttempts
|
|
65
65
|
from .event_type import EventType
|
|
66
66
|
from .feature_flag import FeatureFlag
|
|
67
67
|
from .fields import Fields
|
|
@@ -76,13 +76,9 @@ if typing.TYPE_CHECKING:
|
|
|
76
76
|
from .legacy_search_request_search_method import LegacySearchRequestSearchMethod
|
|
77
77
|
from .legacy_search_response import LegacySearchResponse
|
|
78
78
|
from .member_response import MemberResponse
|
|
79
|
-
from .message_attempt_out import MessageAttemptOut
|
|
80
|
-
from .message_attempt_trigger_type import MessageAttemptTriggerType
|
|
81
|
-
from .message_out import MessageOut
|
|
82
79
|
from .message_response import MessageResponse
|
|
83
|
-
from .message_status import MessageStatus
|
|
84
|
-
from .message_status_text import MessageStatusText
|
|
85
80
|
from .minute_level_schedule_config import MinuteLevelScheduleConfig
|
|
81
|
+
from .not_found_error_response import NotFoundErrorResponse
|
|
86
82
|
from .o_auth_browser_authentication import OAuthBrowserAuthentication
|
|
87
83
|
from .o_auth_token_authentication import OAuthTokenAuthentication
|
|
88
84
|
from .o_auth_type import OAuthType
|
|
@@ -91,8 +87,9 @@ if typing.TYPE_CHECKING:
|
|
|
91
87
|
from .organization_create import OrganizationCreate
|
|
92
88
|
from .organization_metrics import OrganizationMetrics
|
|
93
89
|
from .organization_with_role import OrganizationWithRole
|
|
94
|
-
from .patch_subscription_request import PatchSubscriptionRequest
|
|
95
90
|
from .query_expansion_strategy import QueryExpansionStrategy
|
|
91
|
+
from .rate_limit_error_response import RateLimitErrorResponse
|
|
92
|
+
from .recovery_task import RecoveryTask
|
|
96
93
|
from .response_type import ResponseType
|
|
97
94
|
from .retrieval_strategy import RetrievalStrategy
|
|
98
95
|
from .s_3_config_request import S3ConfigRequest
|
|
@@ -114,11 +111,11 @@ if typing.TYPE_CHECKING:
|
|
|
114
111
|
from .source_rate_limit_response import SourceRateLimitResponse
|
|
115
112
|
from .source_rate_limit_update_request import SourceRateLimitUpdateRequest
|
|
116
113
|
from .subscription_info import SubscriptionInfo
|
|
117
|
-
from .subscription_with_attempts_out import SubscriptionWithAttemptsOut
|
|
118
114
|
from .sync import Sync
|
|
119
115
|
from .sync_config import SyncConfig
|
|
120
116
|
from .sync_create import SyncCreate
|
|
121
117
|
from .sync_details import SyncDetails
|
|
118
|
+
from .sync_event_payload import SyncEventPayload
|
|
122
119
|
from .sync_job import SyncJob
|
|
123
120
|
from .sync_job_details import SyncJobDetails
|
|
124
121
|
from .sync_job_status import SyncJobStatus
|
|
@@ -135,7 +132,10 @@ if typing.TYPE_CHECKING:
|
|
|
135
132
|
from .user_create import UserCreate
|
|
136
133
|
from .user_organization import UserOrganization
|
|
137
134
|
from .validation_error import ValidationError
|
|
135
|
+
from .validation_error_detail import ValidationErrorDetail
|
|
138
136
|
from .validation_error_loc_item import ValidationErrorLocItem
|
|
137
|
+
from .validation_error_response import ValidationErrorResponse
|
|
138
|
+
from .webhook_subscription import WebhookSubscription
|
|
139
139
|
_dynamic_imports: typing.Dict[str, str] = {
|
|
140
140
|
"ActionCheckRequest": ".action_check_request",
|
|
141
141
|
"ActionCheckResponse": ".action_check_response",
|
|
@@ -163,23 +163,21 @@ _dynamic_imports: typing.Dict[str, str] = {
|
|
|
163
163
|
"CheckoutSessionResponse": ".checkout_session_response",
|
|
164
164
|
"Collection": ".collection",
|
|
165
165
|
"CollectionStatus": ".collection_status",
|
|
166
|
-
"CollectionUpdate": ".collection_update",
|
|
167
166
|
"ConfigField": ".config_field",
|
|
168
167
|
"ConfigValues": ".config_values",
|
|
168
|
+
"ConflictErrorResponse": ".conflict_error_response",
|
|
169
169
|
"Connection": ".connection",
|
|
170
170
|
"ConnectionStatus": ".connection_status",
|
|
171
|
-
"CreateSubscriptionRequest": ".create_subscription_request",
|
|
172
171
|
"CursorConfig": ".cursor_config",
|
|
173
172
|
"CustomerPortalRequest": ".customer_portal_request",
|
|
174
173
|
"CustomerPortalResponse": ".customer_portal_response",
|
|
174
|
+
"DeliveryAttempt": ".delivery_attempt",
|
|
175
175
|
"Destination": ".destination",
|
|
176
176
|
"DestinationConfig": ".destination_config",
|
|
177
177
|
"DestinationWithAuthenticationFields": ".destination_with_authentication_fields",
|
|
178
178
|
"DirectAuthentication": ".direct_authentication",
|
|
179
179
|
"EmbeddingModel": ".embedding_model",
|
|
180
180
|
"EmbeddingModelWithAuthenticationFields": ".embedding_model_with_authentication_fields",
|
|
181
|
-
"EndpointOut": ".endpoint_out",
|
|
182
|
-
"EndpointSecretOut": ".endpoint_secret_out",
|
|
183
181
|
"EntityCount": ".entity_count",
|
|
184
182
|
"EntityCountWithDefinition": ".entity_count_with_definition",
|
|
185
183
|
"EntityDefinition": ".entity_definition",
|
|
@@ -189,6 +187,8 @@ _dynamic_imports: typing.Dict[str, str] = {
|
|
|
189
187
|
"EntitySummary": ".entity_summary",
|
|
190
188
|
"EntityType": ".entity_type",
|
|
191
189
|
"EntityTypeStats": ".entity_type_stats",
|
|
190
|
+
"EventMessage": ".event_message",
|
|
191
|
+
"EventMessageWithAttempts": ".event_message_with_attempts",
|
|
192
192
|
"EventType": ".event_type",
|
|
193
193
|
"FeatureFlag": ".feature_flag",
|
|
194
194
|
"Fields": ".fields",
|
|
@@ -203,13 +203,9 @@ _dynamic_imports: typing.Dict[str, str] = {
|
|
|
203
203
|
"LegacySearchRequestSearchMethod": ".legacy_search_request_search_method",
|
|
204
204
|
"LegacySearchResponse": ".legacy_search_response",
|
|
205
205
|
"MemberResponse": ".member_response",
|
|
206
|
-
"MessageAttemptOut": ".message_attempt_out",
|
|
207
|
-
"MessageAttemptTriggerType": ".message_attempt_trigger_type",
|
|
208
|
-
"MessageOut": ".message_out",
|
|
209
206
|
"MessageResponse": ".message_response",
|
|
210
|
-
"MessageStatus": ".message_status",
|
|
211
|
-
"MessageStatusText": ".message_status_text",
|
|
212
207
|
"MinuteLevelScheduleConfig": ".minute_level_schedule_config",
|
|
208
|
+
"NotFoundErrorResponse": ".not_found_error_response",
|
|
213
209
|
"OAuthBrowserAuthentication": ".o_auth_browser_authentication",
|
|
214
210
|
"OAuthTokenAuthentication": ".o_auth_token_authentication",
|
|
215
211
|
"OAuthType": ".o_auth_type",
|
|
@@ -218,8 +214,9 @@ _dynamic_imports: typing.Dict[str, str] = {
|
|
|
218
214
|
"OrganizationCreate": ".organization_create",
|
|
219
215
|
"OrganizationMetrics": ".organization_metrics",
|
|
220
216
|
"OrganizationWithRole": ".organization_with_role",
|
|
221
|
-
"PatchSubscriptionRequest": ".patch_subscription_request",
|
|
222
217
|
"QueryExpansionStrategy": ".query_expansion_strategy",
|
|
218
|
+
"RateLimitErrorResponse": ".rate_limit_error_response",
|
|
219
|
+
"RecoveryTask": ".recovery_task",
|
|
223
220
|
"ResponseType": ".response_type",
|
|
224
221
|
"RetrievalStrategy": ".retrieval_strategy",
|
|
225
222
|
"S3ConfigRequest": ".s_3_config_request",
|
|
@@ -241,11 +238,11 @@ _dynamic_imports: typing.Dict[str, str] = {
|
|
|
241
238
|
"SourceRateLimitResponse": ".source_rate_limit_response",
|
|
242
239
|
"SourceRateLimitUpdateRequest": ".source_rate_limit_update_request",
|
|
243
240
|
"SubscriptionInfo": ".subscription_info",
|
|
244
|
-
"SubscriptionWithAttemptsOut": ".subscription_with_attempts_out",
|
|
245
241
|
"Sync": ".sync",
|
|
246
242
|
"SyncConfig": ".sync_config",
|
|
247
243
|
"SyncCreate": ".sync_create",
|
|
248
244
|
"SyncDetails": ".sync_details",
|
|
245
|
+
"SyncEventPayload": ".sync_event_payload",
|
|
249
246
|
"SyncJob": ".sync_job",
|
|
250
247
|
"SyncJobDetails": ".sync_job_details",
|
|
251
248
|
"SyncJobStatus": ".sync_job_status",
|
|
@@ -262,7 +259,10 @@ _dynamic_imports: typing.Dict[str, str] = {
|
|
|
262
259
|
"UserCreate": ".user_create",
|
|
263
260
|
"UserOrganization": ".user_organization",
|
|
264
261
|
"ValidationError": ".validation_error",
|
|
262
|
+
"ValidationErrorDetail": ".validation_error_detail",
|
|
265
263
|
"ValidationErrorLocItem": ".validation_error_loc_item",
|
|
264
|
+
"ValidationErrorResponse": ".validation_error_response",
|
|
265
|
+
"WebhookSubscription": ".webhook_subscription",
|
|
266
266
|
}
|
|
267
267
|
|
|
268
268
|
|
|
@@ -314,23 +314,21 @@ __all__ = [
|
|
|
314
314
|
"CheckoutSessionResponse",
|
|
315
315
|
"Collection",
|
|
316
316
|
"CollectionStatus",
|
|
317
|
-
"CollectionUpdate",
|
|
318
317
|
"ConfigField",
|
|
319
318
|
"ConfigValues",
|
|
319
|
+
"ConflictErrorResponse",
|
|
320
320
|
"Connection",
|
|
321
321
|
"ConnectionStatus",
|
|
322
|
-
"CreateSubscriptionRequest",
|
|
323
322
|
"CursorConfig",
|
|
324
323
|
"CustomerPortalRequest",
|
|
325
324
|
"CustomerPortalResponse",
|
|
325
|
+
"DeliveryAttempt",
|
|
326
326
|
"Destination",
|
|
327
327
|
"DestinationConfig",
|
|
328
328
|
"DestinationWithAuthenticationFields",
|
|
329
329
|
"DirectAuthentication",
|
|
330
330
|
"EmbeddingModel",
|
|
331
331
|
"EmbeddingModelWithAuthenticationFields",
|
|
332
|
-
"EndpointOut",
|
|
333
|
-
"EndpointSecretOut",
|
|
334
332
|
"EntityCount",
|
|
335
333
|
"EntityCountWithDefinition",
|
|
336
334
|
"EntityDefinition",
|
|
@@ -340,6 +338,8 @@ __all__ = [
|
|
|
340
338
|
"EntitySummary",
|
|
341
339
|
"EntityType",
|
|
342
340
|
"EntityTypeStats",
|
|
341
|
+
"EventMessage",
|
|
342
|
+
"EventMessageWithAttempts",
|
|
343
343
|
"EventType",
|
|
344
344
|
"FeatureFlag",
|
|
345
345
|
"Fields",
|
|
@@ -354,13 +354,9 @@ __all__ = [
|
|
|
354
354
|
"LegacySearchRequestSearchMethod",
|
|
355
355
|
"LegacySearchResponse",
|
|
356
356
|
"MemberResponse",
|
|
357
|
-
"MessageAttemptOut",
|
|
358
|
-
"MessageAttemptTriggerType",
|
|
359
|
-
"MessageOut",
|
|
360
357
|
"MessageResponse",
|
|
361
|
-
"MessageStatus",
|
|
362
|
-
"MessageStatusText",
|
|
363
358
|
"MinuteLevelScheduleConfig",
|
|
359
|
+
"NotFoundErrorResponse",
|
|
364
360
|
"OAuthBrowserAuthentication",
|
|
365
361
|
"OAuthTokenAuthentication",
|
|
366
362
|
"OAuthType",
|
|
@@ -369,8 +365,9 @@ __all__ = [
|
|
|
369
365
|
"OrganizationCreate",
|
|
370
366
|
"OrganizationMetrics",
|
|
371
367
|
"OrganizationWithRole",
|
|
372
|
-
"PatchSubscriptionRequest",
|
|
373
368
|
"QueryExpansionStrategy",
|
|
369
|
+
"RateLimitErrorResponse",
|
|
370
|
+
"RecoveryTask",
|
|
374
371
|
"ResponseType",
|
|
375
372
|
"RetrievalStrategy",
|
|
376
373
|
"S3ConfigRequest",
|
|
@@ -392,11 +389,11 @@ __all__ = [
|
|
|
392
389
|
"SourceRateLimitResponse",
|
|
393
390
|
"SourceRateLimitUpdateRequest",
|
|
394
391
|
"SubscriptionInfo",
|
|
395
|
-
"SubscriptionWithAttemptsOut",
|
|
396
392
|
"Sync",
|
|
397
393
|
"SyncConfig",
|
|
398
394
|
"SyncCreate",
|
|
399
395
|
"SyncDetails",
|
|
396
|
+
"SyncEventPayload",
|
|
400
397
|
"SyncJob",
|
|
401
398
|
"SyncJobDetails",
|
|
402
399
|
"SyncJobStatus",
|
|
@@ -413,5 +410,8 @@ __all__ = [
|
|
|
413
410
|
"UserCreate",
|
|
414
411
|
"UserOrganization",
|
|
415
412
|
"ValidationError",
|
|
413
|
+
"ValidationErrorDetail",
|
|
416
414
|
"ValidationErrorLocItem",
|
|
415
|
+
"ValidationErrorResponse",
|
|
416
|
+
"WebhookSubscription",
|
|
417
417
|
]
|
|
@@ -4,17 +4,20 @@ import typing
|
|
|
4
4
|
|
|
5
5
|
import pydantic
|
|
6
6
|
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
|
|
7
|
-
from .event_type import EventType
|
|
8
7
|
|
|
9
8
|
|
|
10
|
-
class
|
|
9
|
+
class ConflictErrorResponse(UniversalBaseModel):
|
|
11
10
|
"""
|
|
12
|
-
|
|
11
|
+
Response returned when a resource conflict occurs (HTTP 409).
|
|
12
|
+
|
|
13
|
+
This typically occurs when attempting to create a resource that already exists,
|
|
14
|
+
or when an operation cannot be completed due to the current state of a resource.
|
|
13
15
|
"""
|
|
14
16
|
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
17
|
+
detail: str = pydantic.Field()
|
|
18
|
+
"""
|
|
19
|
+
Error message describing the conflict
|
|
20
|
+
"""
|
|
18
21
|
|
|
19
22
|
if IS_PYDANTIC_V2:
|
|
20
23
|
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
# This file was auto-generated by Fern from our API Definition.
|
|
2
|
+
|
|
3
|
+
import datetime as dt
|
|
4
|
+
import typing
|
|
5
|
+
|
|
6
|
+
import pydantic
|
|
7
|
+
from ..core.pydantic_utilities import IS_PYDANTIC_V2, UniversalBaseModel
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class DeliveryAttempt(UniversalBaseModel):
|
|
11
|
+
"""
|
|
12
|
+
A delivery attempt for a webhook message.
|
|
13
|
+
|
|
14
|
+
Each time Airweave attempts to deliver a message to your webhook endpoint,
|
|
15
|
+
a delivery attempt is recorded. Failed attempts are automatically retried
|
|
16
|
+
with exponential backoff.
|
|
17
|
+
"""
|
|
18
|
+
|
|
19
|
+
id: str = pydantic.Field()
|
|
20
|
+
"""
|
|
21
|
+
Unique identifier for this delivery attempt
|
|
22
|
+
"""
|
|
23
|
+
|
|
24
|
+
message_id: str = pydantic.Field()
|
|
25
|
+
"""
|
|
26
|
+
The event message that was being delivered
|
|
27
|
+
"""
|
|
28
|
+
|
|
29
|
+
endpoint_id: str = pydantic.Field()
|
|
30
|
+
"""
|
|
31
|
+
The subscription endpoint this was delivered to
|
|
32
|
+
"""
|
|
33
|
+
|
|
34
|
+
response: typing.Optional[str] = pydantic.Field(default=None)
|
|
35
|
+
"""
|
|
36
|
+
The response body returned by your webhook endpoint (truncated to 1KB)
|
|
37
|
+
"""
|
|
38
|
+
|
|
39
|
+
response_status_code: int = pydantic.Field()
|
|
40
|
+
"""
|
|
41
|
+
HTTP status code returned by your webhook endpoint. 2xx codes indicate success; other codes trigger retries.
|
|
42
|
+
"""
|
|
43
|
+
|
|
44
|
+
status: str = pydantic.Field()
|
|
45
|
+
"""
|
|
46
|
+
Delivery status: `success` (2xx response), `pending` (awaiting delivery), or `failed` (non-2xx response or timeout)
|
|
47
|
+
"""
|
|
48
|
+
|
|
49
|
+
timestamp: dt.datetime = pydantic.Field()
|
|
50
|
+
"""
|
|
51
|
+
When this delivery attempt occurred (ISO 8601 format, UTC)
|
|
52
|
+
"""
|
|
53
|
+
|
|
54
|
+
if IS_PYDANTIC_V2:
|
|
55
|
+
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
|
|
56
|
+
else:
|
|
57
|
+
|
|
58
|
+
class Config:
|
|
59
|
+
frozen = True
|
|
60
|
+
smart_union = True
|
|
61
|
+
extra = pydantic.Extra.allow
|