Skip to content

Commit ff4066f

Browse files
Fetch latest version of server schemas
1 parent 18ab5d3 commit ff4066f

File tree

1 file changed

+29
-2
lines changed

1 file changed

+29
-2
lines changed

src/entitysdk/_server_schemas.py

Lines changed: 29 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,15 @@
11
# generated by datamodel-codegen:
22
# filename: https://staging.openbraininstitute.org/api/entitycore/openapi.json
3-
# timestamp: 2025-06-18T08:10:19+00:00
3+
# timestamp: 2025-06-19T12:22:45+00:00
44

55
from __future__ import annotations
66
from enum import Enum
77
from enum import StrEnum
88
from uuid import UUID
99
from typing import Annotated, Any
10-
from pydantic import BaseModel, Field, RootModel, UUID4
10+
from pydantic import AnyUrl, BaseModel, Field, RootModel, UUID4
1111
from datetime import datetime
12+
from pathlib import Path
1213

1314

1415
class ActivityType(StrEnum):
@@ -47,6 +48,7 @@ class ApiErrorCode(StrEnum):
4748
ASSET_NOT_A_DIRECTORY = "ASSET_NOT_A_DIRECTORY"
4849
ASSET_INVALID_SCHEMA = "ASSET_INVALID_SCHEMA"
4950
ION_NAME_NOT_FOUND = "ION_NAME_NOT_FOUND"
51+
S3_CANNOT_CREATE_PRESIGNED_URL = "S3_CANNOT_CREATE_PRESIGNED_URL"
5052

5153

5254
class AssetLabel(StrEnum):
@@ -105,6 +107,23 @@ class ContributionCreate(BaseModel):
105107
entity_id: Annotated[UUID, Field(title="Entity Id")]
106108

107109

110+
class DetailedFile(BaseModel):
111+
name: Annotated[str, Field(title="Name")]
112+
size: Annotated[int, Field(title="Size")]
113+
last_modified: Annotated[datetime, Field(title="Last Modified")]
114+
115+
116+
class DetailedFileList(BaseModel):
117+
files: Annotated[dict[str, DetailedFile], Field(title="Files")]
118+
119+
120+
class DirectoryUpload(BaseModel):
121+
directory_name: Annotated[Path, Field(title="Directory Name")]
122+
files: Annotated[list[Path], Field(title="Files")]
123+
meta: Annotated[dict[str, Any] | None, Field(title="Meta")] = None
124+
label: AssetLabel | None = None
125+
126+
108127
class EModelCreate(BaseModel):
109128
authorized_public: Annotated[bool | None, Field(title="Authorized Public")] = False
110129
description: Annotated[str, Field(title="Description")]
@@ -1225,6 +1244,11 @@ class SingleNeuronSynaptomeSimulationRead(BaseModel):
12251244
synaptome: NestedSynaptome
12261245

12271246

1247+
class AssetAndPresignedURLS(BaseModel):
1248+
asset: AssetRead
1249+
files: Annotated[dict[str, AnyUrl], Field(title="Files")]
1250+
1251+
12281252
class CircuitRead(BaseModel):
12291253
assets: Annotated[list[AssetRead], Field(title="Assets")]
12301254
authorized_project_id: Annotated[UUID4, Field(title="Authorized Project Id")]
@@ -1284,6 +1308,9 @@ class EModelRead(BaseModel):
12841308

12851309

12861310
class ElectricalCellRecordingRead(BaseModel):
1311+
contributions: Annotated[list[NestedContributionRead] | None, Field(title="Contributions")] = (
1312+
None
1313+
)
12871314
subject: NestedSubjectRead
12881315
created_by: NestedPersonRead
12891316
updated_by: NestedPersonRead

0 commit comments

Comments
 (0)