diff --git a/atproto/xrpc_client/models/com/atproto/admin/defs.py b/atproto/xrpc_client/models/com/atproto/admin/defs.py index 73b8bc6c..d1bae88a 100644 --- a/atproto/xrpc_client/models/com/atproto/admin/defs.py +++ b/atproto/xrpc_client/models/com/atproto/admin/defs.py @@ -73,7 +73,13 @@ class ActionViewDetail(base.ModelBase): id: int reason: str resolvedReports: List['models.ComAtprotoAdminDefs.ReportView'] - subject: Union['models.ComAtprotoAdminDefs.RepoView', 'models.ComAtprotoAdminDefs.RecordView', 'Dict[str, Any]'] + subject: Union[ + 'models.ComAtprotoAdminDefs.RepoView', + 'models.ComAtprotoAdminDefs.RepoViewNotFound', + 'models.ComAtprotoAdminDefs.RecordView', + 'models.ComAtprotoAdminDefs.RecordViewNotFound', + 'Dict[str, Any]', + ] subjectBlobs: List['models.ComAtprotoAdminDefs.BlobView'] createLabelVals: Optional[List[str]] = None negateLabelVals: Optional[List[str]] = None @@ -173,7 +179,13 @@ class ReportViewDetail(base.ModelBase): reasonType: 'models.ComAtprotoModerationDefs.ReasonType' reportedBy: str resolvedByActions: List['models.ComAtprotoAdminDefs.ActionView'] - subject: Union['models.ComAtprotoAdminDefs.RepoView', 'models.ComAtprotoAdminDefs.RecordView', 'Dict[str, Any]'] + subject: Union[ + 'models.ComAtprotoAdminDefs.RepoView', + 'models.ComAtprotoAdminDefs.RepoViewNotFound', + 'models.ComAtprotoAdminDefs.RecordView', + 'models.ComAtprotoAdminDefs.RecordViewNotFound', + 'Dict[str, Any]', + ] reason: Optional[str] = None _type: str = 'com.atproto.admin.defs#reportViewDetail' @@ -239,6 +251,20 @@ class RepoViewDetail(base.ModelBase): _type: str = 'com.atproto.admin.defs#repoViewDetail' +@dataclass +class RepoViewNotFound(base.ModelBase): + + """Definition model for :obj:`com.atproto.admin.defs`. + + Attributes: + did: Did. + """ + + did: str + + _type: str = 'com.atproto.admin.defs#repoViewNotFound' + + @dataclass class RepoRef(base.ModelBase): @@ -307,6 +333,20 @@ class RecordViewDetail(base.ModelBase): _type: str = 'com.atproto.admin.defs#recordViewDetail' +@dataclass +class RecordViewNotFound(base.ModelBase): + + """Definition model for :obj:`com.atproto.admin.defs`. + + Attributes: + uri: Uri. + """ + + uri: str + + _type: str = 'com.atproto.admin.defs#recordViewNotFound' + + @dataclass class Moderation(base.ModelBase): diff --git a/lexicons/com.atproto.admin.defs.json b/lexicons/com.atproto.admin.defs.json index 66b9a674..c6b61402 100644 --- a/lexicons/com.atproto.admin.defs.json +++ b/lexicons/com.atproto.admin.defs.json @@ -35,7 +35,9 @@ "type": "union", "refs": [ "#repoView", - "#recordView" + "#repoViewNotFound", + "#recordView", + "#recordViewNotFound" ] }, "subjectBlobs": {"type": "array", "items": {"type": "ref", "ref": "#blobView"}}, @@ -120,7 +122,9 @@ "type": "union", "refs": [ "#repoView", - "#recordView" + "#repoViewNotFound", + "#recordView", + "#recordViewNotFound" ] }, "reportedBy": {"type": "string", "format": "did"}, @@ -164,6 +168,13 @@ "invitesDisabled": {"type": "boolean"} } }, + "repoViewNotFound": { + "type": "object", + "required": ["did"], + "properties": { + "did": {"type": "string", "format": "did"} + } + }, "repoRef": { "type": "object", "required": ["did"], @@ -201,6 +212,13 @@ "repo": {"type": "ref", "ref": "#repoView"} } }, + "recordViewNotFound": { + "type": "object", + "required": ["uri"], + "properties": { + "uri": {"type": "string", "format": "at-uri"} + } + }, "moderation": { "type": "object", "required": [], diff --git a/lexicons/com.atproto.admin.getRecord.json b/lexicons/com.atproto.admin.getRecord.json index 2b385eea..b0790187 100644 --- a/lexicons/com.atproto.admin.getRecord.json +++ b/lexicons/com.atproto.admin.getRecord.json @@ -16,7 +16,10 @@ "output": { "encoding": "application/json", "schema": {"type": "ref", "ref": "com.atproto.admin.defs#recordViewDetail"} - } + }, + "errors": [ + {"name": "RecordNotFound"} + ] } } } diff --git a/lexicons/com.atproto.admin.getRepo.json b/lexicons/com.atproto.admin.getRepo.json index fea40bcc..972c00ce 100644 --- a/lexicons/com.atproto.admin.getRepo.json +++ b/lexicons/com.atproto.admin.getRepo.json @@ -15,7 +15,10 @@ "output": { "encoding": "application/json", "schema": {"type": "ref", "ref": "com.atproto.admin.defs#repoViewDetail"} - } + }, + "errors": [ + {"name": "RepoNotFound"} + ] } } } diff --git a/lexicons/com.atproto.repo.applyWrites.json b/lexicons/com.atproto.repo.applyWrites.json index 6a6ece8c..025b2721 100644 --- a/lexicons/com.atproto.repo.applyWrites.json +++ b/lexicons/com.atproto.repo.applyWrites.json @@ -42,7 +42,7 @@ "required": ["action", "collection", "value"], "properties": { "collection": {"type": "string", "format": "nsid"}, - "rkey": {"type": "string"}, + "rkey": {"type": "string", "maxLength": 15}, "value": {"type": "unknown"} } }, diff --git a/lexicons/com.atproto.repo.createRecord.json b/lexicons/com.atproto.repo.createRecord.json index 11b56506..3988de24 100644 --- a/lexicons/com.atproto.repo.createRecord.json +++ b/lexicons/com.atproto.repo.createRecord.json @@ -23,7 +23,8 @@ }, "rkey": { "type": "string", - "description": "The key of the record." + "description": "The key of the record.", + "maxLength": 15 }, "validate": { "type": "boolean", diff --git a/lexicons/com.atproto.repo.putRecord.json b/lexicons/com.atproto.repo.putRecord.json index 919306bf..d0067110 100644 --- a/lexicons/com.atproto.repo.putRecord.json +++ b/lexicons/com.atproto.repo.putRecord.json @@ -24,7 +24,8 @@ }, "rkey": { "type": "string", - "description": "The key of the record." + "description": "The key of the record.", + "maxLength": 15 }, "validate": { "type": "boolean",