contextbase-shared-types 0.2.6__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.
@@ -0,0 +1,9 @@
1
+ Metadata-Version: 2.3
2
+ Name: contextbase-shared-types
3
+ Version: 0.2.6
4
+ Summary: Generated Python models for TypeScript-owned control-plane contracts
5
+ Author: Alizain Feerasta
6
+ Author-email: Alizain Feerasta <alizain.feerasta@gmail.com>
7
+ Requires-Dist: pydantic>=2.12.0
8
+ Requires-Dist: typing-extensions>=4.0.0
9
+ Requires-Python: >=3.14, <3.15
@@ -0,0 +1,15 @@
1
+ shared_types/__init__.py,sha256=nbLfMQWdqo2GdLRBo98lEs7dVLtMi2_3Rk8nnQCfJdI,641
2
+ shared_types/api_key_auth.py,sha256=7Rl1PsEmcSl9sDi4tbJ40kqNkoofOL1ZJ7mPsT7BdhM,73
3
+ shared_types/authenticated_account.py,sha256=U3A_bSSy3z-e9bzM3lVZ47cOdowlqTCk49OaMuCsOo8,99
4
+ shared_types/binding_auth_none.py,sha256=0tPAzMUEy1lYxAYUbYaXR_6ASfl5iSuLJUYFlwGZBG0,83
5
+ shared_types/client_credentials_auth.py,sha256=4iqO4lU5n_6g_iDMIAtnufRVb9HcApWaaC6cjsWRgAU,95
6
+ shared_types/dagster_binding_plan.py,sha256=pMwmsFbPIxXo5i6dX8LNSB6pP4XCWnBVjAEwCDwAcmM,253
7
+ shared_types/generated/__init__.py,sha256=srxLmtuShAslKDlHfk8cPtEvopr1NlGpWS40bpuyjiw,72
8
+ shared_types/generated/oauth-access-token-success.schema.json,sha256=KeqVUDn0OPyKisBaJx4QJ6zAVPMEw6ZpBRDCJAYDdaM,536
9
+ shared_types/generated/oauth_access_token.py,sha256=ixDrpLC89NoKGCCT6XqmNoc69scdW5EMshnQFQXWQyA,498
10
+ shared_types/generated/shared-graph.schema.json,sha256=c1V8i6nPZsRbri2qY58AL_6ToM-_z8WgQqrfW9V2EcY,4648
11
+ shared_types/generated/shared_graph.py,sha256=7UIRkd_gGMUeZVHg5hPf1Ns8fiQCQCHK4pEG148Wato,2079
12
+ shared_types/oauth_access_token.py,sha256=S2qgZxGEwpCqBMbFyJE11ENPse2njjcf6D-dKi7i_YY,105
13
+ contextbase_shared_types-0.2.6.dist-info/WHEEL,sha256=i9aSRDivn5iP9LaR1BLQX2GNAuriQWPsFwbbWygTX2k,81
14
+ contextbase_shared_types-0.2.6.dist-info/METADATA,sha256=060Mcik9atG2g4WMhV1_pRlMLZ-7hBhUo-wPyc7KTEI,334
15
+ contextbase_shared_types-0.2.6.dist-info/RECORD,,
@@ -0,0 +1,4 @@
1
+ Wheel-Version: 1.0
2
+ Generator: uv 0.11.15
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
@@ -0,0 +1,23 @@
1
+ from .api_key_auth import ApiKeyAuth
2
+ from .authenticated_account import AuthenticatedAccountRef
3
+ from .binding_auth_none import BindingAuthNone
4
+ from .client_credentials_auth import ClientCredentialsAuth
5
+ from .dagster_binding_plan import (
6
+ BindingModelName,
7
+ BindingModels,
8
+ DagsterAllPlanBinding,
9
+ DagsterBindingPlanAll,
10
+ )
11
+ from .oauth_access_token import OAuthAccessTokenSuccess
12
+
13
+ __all__ = [
14
+ "ApiKeyAuth",
15
+ "AuthenticatedAccountRef",
16
+ "BindingAuthNone",
17
+ "ClientCredentialsAuth",
18
+ "BindingModelName",
19
+ "BindingModels",
20
+ "DagsterAllPlanBinding",
21
+ "DagsterBindingPlanAll",
22
+ "OAuthAccessTokenSuccess",
23
+ ]
@@ -0,0 +1,3 @@
1
+ from .generated.shared_graph import ApiKeyAuth
2
+
3
+ __all__ = ["ApiKeyAuth"]
@@ -0,0 +1,3 @@
1
+ from .generated.shared_graph import AuthenticatedAccountRef
2
+
3
+ __all__ = ["AuthenticatedAccountRef"]
@@ -0,0 +1,3 @@
1
+ from .generated.shared_graph import BindingAuthNone
2
+
3
+ __all__ = ["BindingAuthNone"]
@@ -0,0 +1,3 @@
1
+ from .generated.shared_graph import ClientCredentialsAuth
2
+
3
+ __all__ = ["ClientCredentialsAuth"]
@@ -0,0 +1,13 @@
1
+ from .generated.shared_graph import (
2
+ BindingModelName,
3
+ BindingModels,
4
+ DagsterAllPlanBinding,
5
+ DagsterBindingPlanAll,
6
+ )
7
+
8
+ __all__ = [
9
+ "BindingModelName",
10
+ "BindingModels",
11
+ "DagsterAllPlanBinding",
12
+ "DagsterBindingPlanAll",
13
+ ]
@@ -0,0 +1 @@
1
+ # Generated shared graph and wire-contract models live in this package.
@@ -0,0 +1,28 @@
1
+ {
2
+ "$defs": {
3
+ "__schema0": {
4
+ "minLength": 1,
5
+ "type": "string"
6
+ },
7
+ "__schema1": {
8
+ "format": "date-time",
9
+ "type": "string"
10
+ },
11
+ "__schema2": {}
12
+ },
13
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
14
+ "additionalProperties": {
15
+ "$ref": "#/$defs/__schema2"
16
+ },
17
+ "properties": {
18
+ "accessToken": {
19
+ "$ref": "#/$defs/__schema0"
20
+ },
21
+ "accessTokenExpiresAt": {
22
+ "$ref": "#/$defs/__schema1"
23
+ }
24
+ },
25
+ "required": ["accessToken", "accessTokenExpiresAt"],
26
+ "title": "OAuthAccessTokenSuccess",
27
+ "type": "object"
28
+ }
@@ -0,0 +1,18 @@
1
+ # generated by datamodel-codegen:
2
+ # filename: oauth-access-token-success.schema.json
3
+
4
+ from typing import Annotated, Any
5
+ from pydantic import AwareDatetime, BaseModel, ConfigDict, Field
6
+
7
+
8
+ type FieldSchema2 = Any
9
+
10
+
11
+ class OAuthAccessTokenSuccess(BaseModel):
12
+ model_config = ConfigDict(
13
+ extra="allow",
14
+ )
15
+ access_token: Annotated[str, Field(alias="accessToken", min_length=1)]
16
+ access_token_expires_at: Annotated[
17
+ AwareDatetime, Field(alias="accessTokenExpiresAt")
18
+ ]
@@ -0,0 +1,247 @@
1
+ {
2
+ "$defs": {
3
+ "__schema0": {
4
+ "$ref": "#/$defs/__schema1"
5
+ },
6
+ "__schema1": {
7
+ "additionalProperties": false,
8
+ "properties": {
9
+ "api_key": {
10
+ "$ref": "#/$defs/__schema2"
11
+ },
12
+ "type": {
13
+ "$ref": "#/$defs/__schema3"
14
+ }
15
+ },
16
+ "required": ["api_key", "type"],
17
+ "title": "ApiKeyAuth",
18
+ "type": "object"
19
+ },
20
+ "__schema2": {
21
+ "minLength": 1,
22
+ "type": "string"
23
+ },
24
+ "__schema3": {
25
+ "const": "api_key",
26
+ "type": "string"
27
+ },
28
+ "__schema4": {
29
+ "$ref": "#/$defs/__schema5"
30
+ },
31
+ "__schema5": {
32
+ "additionalProperties": false,
33
+ "properties": {
34
+ "account_id": {
35
+ "$ref": "#/$defs/__schema6"
36
+ },
37
+ "provider_id": {
38
+ "$ref": "#/$defs/__schema7"
39
+ },
40
+ "type": {
41
+ "$ref": "#/$defs/__schema8"
42
+ }
43
+ },
44
+ "required": ["account_id", "provider_id", "type"],
45
+ "title": "AuthenticatedAccountRef",
46
+ "type": "object"
47
+ },
48
+ "__schema6": {
49
+ "minLength": 1,
50
+ "type": "string"
51
+ },
52
+ "__schema7": {
53
+ "minLength": 1,
54
+ "type": "string"
55
+ },
56
+ "__schema8": {
57
+ "const": "authenticated_account",
58
+ "type": "string"
59
+ },
60
+ "__schema9": {
61
+ "$ref": "#/$defs/__schema10"
62
+ },
63
+ "__schema10": {
64
+ "additionalProperties": false,
65
+ "properties": {
66
+ "type": {
67
+ "$ref": "#/$defs/__schema11"
68
+ }
69
+ },
70
+ "required": ["type"],
71
+ "title": "BindingAuthNone",
72
+ "type": "object"
73
+ },
74
+ "__schema11": {
75
+ "const": "none",
76
+ "type": "string"
77
+ },
78
+ "__schema12": {
79
+ "$ref": "#/$defs/__schema13"
80
+ },
81
+ "__schema13": {
82
+ "additionalProperties": false,
83
+ "properties": {
84
+ "client_id": {
85
+ "$ref": "#/$defs/__schema14"
86
+ },
87
+ "client_secret": {
88
+ "$ref": "#/$defs/__schema15"
89
+ },
90
+ "type": {
91
+ "$ref": "#/$defs/__schema16"
92
+ }
93
+ },
94
+ "required": ["client_id", "client_secret", "type"],
95
+ "title": "ClientCredentialsAuth",
96
+ "type": "object"
97
+ },
98
+ "__schema14": {
99
+ "minLength": 1,
100
+ "type": "string"
101
+ },
102
+ "__schema15": {
103
+ "minLength": 1,
104
+ "type": "string"
105
+ },
106
+ "__schema16": {
107
+ "const": "client_credentials",
108
+ "type": "string"
109
+ },
110
+ "__schema17": {
111
+ "additionalProperties": false,
112
+ "properties": {
113
+ "bindings": {
114
+ "$ref": "#/$defs/__schema18"
115
+ },
116
+ "generated_at": {
117
+ "$ref": "#/$defs/__schema27"
118
+ },
119
+ "version": {
120
+ "$ref": "#/$defs/__schema28"
121
+ }
122
+ },
123
+ "required": ["bindings", "generated_at", "version"],
124
+ "title": "DagsterBindingPlanAll",
125
+ "type": "object"
126
+ },
127
+ "__schema18": {
128
+ "items": {
129
+ "additionalProperties": false,
130
+ "properties": {
131
+ "auth": {
132
+ "$ref": "#/$defs/__schema19"
133
+ },
134
+ "binding_id": {
135
+ "$ref": "#/$defs/__schema20"
136
+ },
137
+ "config": {
138
+ "$ref": "#/$defs/__schema21"
139
+ },
140
+ "mode": {
141
+ "$ref": "#/$defs/__schema22"
142
+ },
143
+ "models": {
144
+ "$ref": "#/$defs/__schema23"
145
+ },
146
+ "plugin_id": {
147
+ "$ref": "#/$defs/__schema26"
148
+ }
149
+ },
150
+ "required": ["auth", "binding_id", "config", "mode", "plugin_id"],
151
+ "title": "DagsterAllPlanBinding",
152
+ "type": "object"
153
+ },
154
+ "type": "array"
155
+ },
156
+ "__schema19": {
157
+ "oneOf": [
158
+ {
159
+ "$ref": "#/$defs/__schema10"
160
+ },
161
+ {
162
+ "$ref": "#/$defs/__schema5"
163
+ },
164
+ {
165
+ "$ref": "#/$defs/__schema1"
166
+ },
167
+ {
168
+ "$ref": "#/$defs/__schema13"
169
+ }
170
+ ],
171
+ "title": "BindingAuth"
172
+ },
173
+ "__schema20": {
174
+ "format": "uuid",
175
+ "type": "string"
176
+ },
177
+ "__schema21": {
178
+ "additionalProperties": {},
179
+ "propertyNames": {
180
+ "type": "string"
181
+ },
182
+ "type": "object"
183
+ },
184
+ "__schema22": {
185
+ "const": "dagster",
186
+ "type": "string"
187
+ },
188
+ "__schema23": {
189
+ "additionalProperties": false,
190
+ "properties": {
191
+ "active": {
192
+ "$ref": "#/$defs/__schema24"
193
+ },
194
+ "filter": {
195
+ "$ref": "#/$defs/__schema25"
196
+ }
197
+ },
198
+ "title": "BindingModels",
199
+ "type": "object"
200
+ },
201
+ "__schema24": {
202
+ "items": {
203
+ "minLength": 1,
204
+ "title": "BindingModelName",
205
+ "type": "string"
206
+ },
207
+ "type": "array"
208
+ },
209
+ "__schema25": {
210
+ "minLength": 1,
211
+ "type": "string"
212
+ },
213
+ "__schema26": {
214
+ "minLength": 1,
215
+ "type": "string"
216
+ },
217
+ "__schema27": {
218
+ "format": "date-time",
219
+ "type": "string"
220
+ },
221
+ "__schema28": {
222
+ "const": 1,
223
+ "type": "number"
224
+ }
225
+ },
226
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
227
+ "additionalProperties": false,
228
+ "properties": {
229
+ "api_key_auth": {
230
+ "$ref": "#/$defs/__schema0"
231
+ },
232
+ "authenticated_account": {
233
+ "$ref": "#/$defs/__schema4"
234
+ },
235
+ "binding_auth_none": {
236
+ "$ref": "#/$defs/__schema9"
237
+ },
238
+ "client_credentials_auth": {
239
+ "$ref": "#/$defs/__schema12"
240
+ },
241
+ "dagster_binding_plan": {
242
+ "$ref": "#/$defs/__schema17"
243
+ }
244
+ },
245
+ "title": "SharedGraph",
246
+ "type": "object"
247
+ }
@@ -0,0 +1,86 @@
1
+ # generated by datamodel-codegen:
2
+ # filename: shared-graph.schema.json
3
+
4
+ from typing import Annotated, Any, Literal
5
+ from pydantic import AwareDatetime, BaseModel, ConfigDict, Field
6
+ from uuid import UUID
7
+
8
+
9
+ type BindingModelName = Annotated[str, Field(min_length=1, title="BindingModelName")]
10
+
11
+
12
+ class ApiKeyAuth(BaseModel):
13
+ model_config = ConfigDict(
14
+ extra="forbid",
15
+ )
16
+ api_key: Annotated[str, Field(min_length=1)]
17
+ type: Literal["api_key"]
18
+
19
+
20
+ class AuthenticatedAccountRef(BaseModel):
21
+ model_config = ConfigDict(
22
+ extra="forbid",
23
+ )
24
+ account_id: Annotated[str, Field(min_length=1)]
25
+ provider_id: Annotated[str, Field(min_length=1)]
26
+ type: Literal["authenticated_account"]
27
+
28
+
29
+ class BindingAuthNone(BaseModel):
30
+ model_config = ConfigDict(
31
+ extra="forbid",
32
+ )
33
+ type: Literal["none"]
34
+
35
+
36
+ class ClientCredentialsAuth(BaseModel):
37
+ model_config = ConfigDict(
38
+ extra="forbid",
39
+ )
40
+ client_id: Annotated[str, Field(min_length=1)]
41
+ client_secret: Annotated[str, Field(min_length=1)]
42
+ type: Literal["client_credentials"]
43
+
44
+
45
+ class BindingModels(BaseModel):
46
+ model_config = ConfigDict(
47
+ extra="forbid",
48
+ )
49
+ active: list[BindingModelName] | None = None
50
+ filter: Annotated[str | None, Field(min_length=1)] = None
51
+
52
+
53
+ type FieldSchema0 = ApiKeyAuth
54
+
55
+
56
+ type FieldSchema4 = AuthenticatedAccountRef
57
+
58
+
59
+ type FieldSchema9 = BindingAuthNone
60
+
61
+
62
+ type FieldSchema12 = ClientCredentialsAuth
63
+
64
+
65
+ class DagsterAllPlanBinding(BaseModel):
66
+ model_config = ConfigDict(
67
+ extra="forbid",
68
+ )
69
+ auth: Annotated[
70
+ BindingAuthNone | AuthenticatedAccountRef | ApiKeyAuth | ClientCredentialsAuth,
71
+ Field(title="BindingAuth"),
72
+ ]
73
+ binding_id: UUID
74
+ config: dict[str, Any]
75
+ mode: Literal["dagster"]
76
+ models: BindingModels | None = None
77
+ plugin_id: Annotated[str, Field(min_length=1)]
78
+
79
+
80
+ class DagsterBindingPlanAll(BaseModel):
81
+ model_config = ConfigDict(
82
+ extra="forbid",
83
+ )
84
+ bindings: list[DagsterAllPlanBinding]
85
+ generated_at: AwareDatetime
86
+ version: Literal[1]
@@ -0,0 +1,3 @@
1
+ from .generated.oauth_access_token import OAuthAccessTokenSuccess
2
+
3
+ __all__ = ["OAuthAccessTokenSuccess"]