@getcirrus/space-conformance 0.0.0 → 0.2.0

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.
Files changed (80) hide show
  1. package/dist/base-CGsQgOwR.d.ts +472 -0
  2. package/dist/base-CGsQgOwR.d.ts.map +1 -0
  3. package/dist/cli.js +26 -18
  4. package/dist/cli.js.map +1 -1
  5. package/dist/coverage-cK1NBo-P.js +2250 -0
  6. package/dist/coverage-cK1NBo-P.js.map +1 -0
  7. package/dist/descriptors-BUCV_BuG.js +4428 -0
  8. package/dist/descriptors-BUCV_BuG.js.map +1 -0
  9. package/dist/full-CKsHg6ox.js +852 -0
  10. package/dist/full-CKsHg6ox.js.map +1 -0
  11. package/dist/full.d.ts +44 -17
  12. package/dist/full.d.ts.map +1 -1
  13. package/dist/full.js +3 -3
  14. package/dist/index.d.ts +90 -28
  15. package/dist/index.d.ts.map +1 -1
  16. package/dist/index.js +115 -93
  17. package/dist/index.js.map +1 -1
  18. package/lexicons/MANIFEST.json +4 -4
  19. package/lexicons/managedspace/checkAccess.json +44 -0
  20. package/lexicons/managedspace/policy.json +22 -0
  21. package/lexicons/memberspace/defs.json +22 -0
  22. package/lexicons/{simplespace → memberspace}/listMembers.json +15 -17
  23. package/lexicons/memberspace/member.json +23 -0
  24. package/lexicons/memberspace/policy.json +40 -0
  25. package/lexicons/memberspace/putMembers.json +43 -0
  26. package/lexicons/memberspace/removeMembers.json +43 -0
  27. package/lexicons/personalspace/policy.json +11 -0
  28. package/lexicons/space/applyWrites.json +6 -11
  29. package/lexicons/space/authorizeSpaceSync.json +109 -0
  30. package/lexicons/space/clearRecords.json +34 -0
  31. package/lexicons/space/confirmRegistration.json +44 -0
  32. package/lexicons/space/createRecord.json +7 -14
  33. package/lexicons/space/createSpace.json +58 -0
  34. package/lexicons/space/defs.json +61 -16
  35. package/lexicons/space/deleteRecord.json +5 -9
  36. package/lexicons/space/deleteSpace.json +31 -0
  37. package/lexicons/space/exportSpaceMeta.json +31 -0
  38. package/lexicons/space/getBlob.json +4 -7
  39. package/lexicons/space/getDelegationToken.json +3 -5
  40. package/lexicons/space/getLatestCommit.json +8 -7
  41. package/lexicons/space/getRecord.json +9 -9
  42. package/lexicons/space/getRepo.json +8 -11
  43. package/lexicons/space/getSpace.json +43 -0
  44. package/lexicons/space/importRepo.json +27 -0
  45. package/lexicons/space/importSpaceMeta.json +25 -0
  46. package/lexicons/space/listBlobs.json +3 -10
  47. package/lexicons/space/listRecords.json +10 -16
  48. package/lexicons/space/listRepoOps.json +23 -23
  49. package/lexicons/space/listSpaces.json +30 -14
  50. package/lexicons/space/listWriters.json +66 -0
  51. package/lexicons/space/notifyCredentialsRevoked.json +30 -0
  52. package/lexicons/space/notifyRepoUpdate.json +44 -0
  53. package/lexicons/space/notifySpaceUpdate.json +53 -0
  54. package/lexicons/space/policy.json +26 -0
  55. package/lexicons/space/putRecord.json +7 -14
  56. package/lexicons/space/removeWriter.json +35 -0
  57. package/lexicons/space/updateSpace.json +43 -0
  58. package/package.json +11 -11
  59. package/dist/base-D8a-ZK57.d.ts +0 -249
  60. package/dist/base-D8a-ZK57.d.ts.map +0 -1
  61. package/dist/coverage-DhJZu8P8.js +0 -1914
  62. package/dist/coverage-DhJZu8P8.js.map +0 -1
  63. package/dist/full-D4ufJLcw.js +0 -409
  64. package/dist/full-D4ufJLcw.js.map +0 -1
  65. package/dist/operator-BErXCDow.js +0 -923
  66. package/dist/operator-BErXCDow.js.map +0 -1
  67. package/lexicons/simplespace/addMember.json +0 -37
  68. package/lexicons/simplespace/checkUserAccess.json +0 -43
  69. package/lexicons/simplespace/createSpace.json +0 -74
  70. package/lexicons/simplespace/defs.json +0 -47
  71. package/lexicons/simplespace/deleteSpace.json +0 -32
  72. package/lexicons/simplespace/getSpace.json +0 -53
  73. package/lexicons/simplespace/removeMember.json +0 -37
  74. package/lexicons/simplespace/updateSpace.json +0 -57
  75. package/lexicons/space/getSpaceCredential.json +0 -67
  76. package/lexicons/space/listRepos.json +0 -75
  77. package/lexicons/space/notifySpaceDeleted.json +0 -24
  78. package/lexicons/space/notifyWrite.json +0 -38
  79. package/lexicons/space/registerNotify.json +0 -49
  80. package/lexicons/space/unregisterNotify.json +0 -29
@@ -4,30 +4,26 @@
4
4
  "defs": {
5
5
  "main": {
6
6
  "type": "query",
7
- "description": "Get a single record from a permissioned space. Callable with either OAuth (for the authenticated user's own data) or a space credential (for syncing services). Throws RepoNotFound when the account holds no repo in the space; this does not distinguish a member that has never written from a non-member.",
7
+ "description": "Get a single record from a space repo. Responses are authenticated with a MAC. Requires auth as the repo's account or with a space credential; implemented by PDS.",
8
8
  "parameters": {
9
9
  "type": "params",
10
10
  "required": ["space", "repo", "collection", "rkey"],
11
11
  "properties": {
12
12
  "space": {
13
13
  "type": "string",
14
- "format": "space-ref",
15
- "description": "Reference to the space."
14
+ "format": "space-ref"
16
15
  },
17
16
  "repo": {
18
17
  "type": "string",
19
- "format": "did",
20
- "description": "The DID of the account whose repo to read from."
18
+ "format": "did"
21
19
  },
22
20
  "collection": {
23
21
  "type": "string",
24
- "format": "nsid",
25
- "description": "The NSID of the record collection."
22
+ "format": "nsid"
26
23
  },
27
24
  "rkey": {
28
25
  "type": "string",
29
- "format": "record-key",
30
- "description": "The Record Key."
26
+ "format": "record-key"
31
27
  }
32
28
  }
33
29
  },
@@ -52,6 +48,10 @@
52
48
  }
53
49
  },
54
50
  "errors": [
51
+ {
52
+ "name": "InvalidSpaceMac",
53
+ "description": "The MAC requested in the Accept-Signature header is missing or invalid."
54
+ },
55
55
  {
56
56
  "name": "RecordNotFound"
57
57
  },
@@ -4,32 +4,29 @@
4
4
  "defs": {
5
5
  "main": {
6
6
  "type": "query",
7
- "description": "Download an account's permissioned repo within a space as a CAR file, for full-state recovery. The CAR declares two roots in order: the signed commit, then a DRISL (DAG-CBOR) index mapping '{collection}/{rkey}' to record CID. Record blocks follow, in the same canonical DAG-CBOR key order as the index (length-first, then bytewise). Blobs are not included and are fetched separately via getBlob. Served by a repo host. Callable with either OAuth (for the authenticated user's own data) or a space credential (for syncing services).",
7
+ "description": "Download a space repo as a STAR file. Responses are authenticated with a MAC. Requires auth as the repo's account or with a space credential; implemented by PDS.",
8
8
  "parameters": {
9
9
  "type": "params",
10
10
  "required": ["space", "repo"],
11
11
  "properties": {
12
12
  "space": {
13
13
  "type": "string",
14
- "format": "space-ref",
15
- "description": "Reference to the space."
14
+ "format": "space-ref"
16
15
  },
17
16
  "repo": {
18
17
  "type": "string",
19
- "format": "did",
20
- "description": "The DID of the account whose repo to download."
21
- },
22
- "excludeValues": {
23
- "type": "boolean",
24
- "default": false,
25
- "description": "If true, omit the record blocks and return only the commit and index roots. The index is still fully authenticated by folding its entries into a set hash and comparing against the commit, so a syncer can diff it against a local copy and fetch just the records it lacks. Note the resulting CAR declares two roots and carries no non-root blocks."
18
+ "format": "did"
26
19
  }
27
20
  }
28
21
  },
29
22
  "output": {
30
- "encoding": "application/vnd.ipld.car"
23
+ "encoding": "application/vnd.dasl.star"
31
24
  },
32
25
  "errors": [
26
+ {
27
+ "name": "InvalidSpaceMac",
28
+ "description": "The MAC requested in the Accept-Signature header is missing or invalid."
29
+ },
33
30
  { "name": "SpaceNotFound" },
34
31
  { "name": "RepoNotFound" },
35
32
  { "name": "RepoTakendown" },
@@ -0,0 +1,43 @@
1
+ {
2
+ "lexicon": 1,
3
+ "id": "com.atproto.space.getSpace",
4
+ "defs": {
5
+ "main": {
6
+ "type": "query",
7
+ "description": "Get a space and its policy. Requires auth as the space authority, implemented by PDS.",
8
+ "parameters": {
9
+ "type": "params",
10
+ "required": ["space"],
11
+ "properties": {
12
+ "space": {
13
+ "type": "string",
14
+ "format": "space-ref"
15
+ }
16
+ }
17
+ },
18
+ "output": {
19
+ "encoding": "application/json",
20
+ "schema": {
21
+ "type": "object",
22
+ "required": ["space", "policy"],
23
+ "properties": {
24
+ "space": {
25
+ "type": "string",
26
+ "format": "space-ref"
27
+ },
28
+ "policy": {
29
+ "type": "union",
30
+ "description": "PDSes must support all of the listed policies. Other space hosts may support only some of them, and any host may support policies beyond those listed.",
31
+ "refs": [
32
+ "com.atproto.personalspace.policy",
33
+ "com.atproto.memberspace.policy",
34
+ "com.atproto.managedspace.policy"
35
+ ]
36
+ }
37
+ }
38
+ }
39
+ },
40
+ "errors": [{ "name": "SpaceNotFound" }, { "name": "NotAuthorized" }]
41
+ }
42
+ }
43
+ }
@@ -0,0 +1,27 @@
1
+ {
2
+ "lexicon": 1,
3
+ "id": "com.atproto.space.importRepo",
4
+ "defs": {
5
+ "main": {
6
+ "type": "procedure",
7
+ "description": "Import the authenticated account's space repo from a STAR file, for account migration. If the account is the space's authority, the space must first be imported with importSpaceMeta. Requires auth, implemented by PDS.",
8
+ "input": {
9
+ "encoding": "application/vnd.dasl.star"
10
+ },
11
+ "errors": [
12
+ {
13
+ "name": "SpaceNotFound",
14
+ "description": "The account is the space's authority, and the space has not been imported yet."
15
+ },
16
+ {
17
+ "name": "InvalidRepoFile",
18
+ "description": "The STAR file is malformed or fails verification."
19
+ },
20
+ {
21
+ "name": "RepoMismatch",
22
+ "description": "The repo in the STAR file does not belong to the authenticated account."
23
+ }
24
+ ]
25
+ }
26
+ }
27
+ }
@@ -0,0 +1,25 @@
1
+ {
2
+ "lexicon": 1,
3
+ "id": "com.atproto.space.importSpaceMeta",
4
+ "defs": {
5
+ "main": {
6
+ "type": "procedure",
7
+ "description": "Import a space's state from an archive produced by exportSpaceMeta, for account migration. Must be called before importing the authority's space repo with importRepo. Requires auth as the space authority, implemented by PDS.",
8
+ "input": {
9
+ "encoding": "application/vnd.dasl.star"
10
+ },
11
+ "errors": [
12
+ {
13
+ "name": "NotAuthorized"
14
+ },
15
+ {
16
+ "name": "UnsupportedPolicy"
17
+ },
18
+ {
19
+ "name": "InvalidSpaceMeta",
20
+ "description": "The STAR file is malformed or fails verification."
21
+ }
22
+ ]
23
+ }
24
+ }
25
+ }
@@ -4,25 +4,18 @@
4
4
  "defs": {
5
5
  "main": {
6
6
  "type": "query",
7
- "description": "List the CIDs of blobs referenced by an account's records within a permissioned space, optionally since some revision of that repo. Lets a syncer discover which blobs to fetch via getBlob, and lets an account enumerate the blobs it must carry when migrating a permissioned repo. Scoped to one space: blobs behind permissioned records are never enumerated by com.atproto.sync.listBlobs, which is unauthenticated. Callable with either OAuth (for the authenticated user's own data) or a space credential (for syncing services).",
7
+ "description": "List blob CIDs referenced by records in a space repo. Requires auth as the repo's account or with a space credential; implemented by PDS.",
8
8
  "parameters": {
9
9
  "type": "params",
10
10
  "required": ["space", "repo"],
11
11
  "properties": {
12
12
  "space": {
13
13
  "type": "string",
14
- "format": "space-ref",
15
- "description": "Reference to the space."
14
+ "format": "space-ref"
16
15
  },
17
16
  "repo": {
18
17
  "type": "string",
19
- "format": "did",
20
- "description": "The DID of the account whose blobs to list."
21
- },
22
- "since": {
23
- "type": "string",
24
- "format": "tid",
25
- "description": "Optional revision of the permissioned repo to list blobs since."
18
+ "format": "did"
26
19
  },
27
20
  "limit": {
28
21
  "type": "integer",
@@ -4,44 +4,36 @@
4
4
  "defs": {
5
5
  "main": {
6
6
  "type": "query",
7
- "description": "List the records in an account's repo within a permissioned space, optionally filtered by collection. By default each record's value is inlined; set excludeValues for a metadata-only listing (collection, rkey, cid). Used for full-state recovery. Callable with either OAuth (for the authenticated user's own data) or a space credential (for syncing services). Throws RepoNotFound when the account holds no repo in the space; this does not distinguish a member that has never written from a non-member.",
7
+ "description": "List records in a space repo, optionally filtered by collection. Requires auth as the repo's account or with a space credential; implemented by PDS.",
8
8
  "parameters": {
9
9
  "type": "params",
10
10
  "required": ["space", "repo"],
11
11
  "properties": {
12
12
  "space": {
13
13
  "type": "string",
14
- "format": "space-ref",
15
- "description": "Reference to the space."
14
+ "format": "space-ref"
16
15
  },
17
16
  "repo": {
18
17
  "type": "string",
19
- "format": "did",
20
- "description": "The DID of the account whose repo to list."
18
+ "format": "did"
21
19
  },
22
20
  "collection": {
23
21
  "type": "string",
24
22
  "format": "nsid",
25
- "description": "The NSID of the record collection. If omitted, lists records across all collections."
23
+ "description": "If omitted, lists records across all collections."
26
24
  },
27
25
  "limit": {
28
26
  "type": "integer",
29
27
  "minimum": 1,
30
28
  "maximum": 1000,
31
- "default": 50,
32
- "description": "The number of records to return."
29
+ "default": 50
33
30
  },
34
31
  "cursor": {
35
32
  "type": "string"
36
33
  },
37
- "reverse": {
38
- "type": "boolean",
39
- "description": "Flag to reverse the order of the returned records."
40
- },
41
34
  "excludeValues": {
42
35
  "type": "boolean",
43
- "default": false,
44
- "description": "If true, omit inlined record values and return only metadata (collection, rkey, cid)."
36
+ "default": false
45
37
  }
46
38
  }
47
39
  },
@@ -79,6 +71,9 @@
79
71
  },
80
72
  {
81
73
  "name": "RepoDeactivated"
74
+ },
75
+ {
76
+ "name": "InvalidCursor"
82
77
  }
83
78
  ]
84
79
  },
@@ -99,8 +94,7 @@
99
94
  "format": "cid"
100
95
  },
101
96
  "value": {
102
- "type": "unknown",
103
- "description": "The record's value. Inlined by default; omitted when excludeValues is set."
97
+ "type": "unknown"
104
98
  }
105
99
  }
106
100
  }
@@ -4,41 +4,35 @@
4
4
  "defs": {
5
5
  "main": {
6
6
  "type": "query",
7
- "description": "List the operation log for an account's permissioned repo within a space, returning operations after a given revision. Primary incremental sync mechanism. By default each created or updated operation inlines the record's current value; set excludeValues for metadata-only entries. Note the oplog is a transport optimization with no history guarantee: a host may compact it or drop it, and it does not survive account migration, so omitting `since` returns the retained window rather than the repo's full history. Use getRepo for an initial sync or when a `since` revision is no longer available. Callable with either OAuth (for the authenticated user's own data) or a space credential (for syncing services).",
7
+ "description": "List operations on a space repo after a given revision. Used for incremental sync. Hosts may truncate the log, so use getRepo for a full sync. Responses are authenticated with a MAC. Requires auth as the repo's account or with a space credential; implemented by PDS.",
8
8
  "parameters": {
9
9
  "type": "params",
10
10
  "required": ["space", "repo"],
11
11
  "properties": {
12
12
  "space": {
13
13
  "type": "string",
14
- "format": "space-ref",
15
- "description": "Reference to the space."
14
+ "format": "space-ref"
16
15
  },
17
16
  "repo": {
18
17
  "type": "string",
19
- "format": "did",
20
- "description": "The DID of the account whose oplog to retrieve."
18
+ "format": "did"
21
19
  },
22
20
  "since": {
23
21
  "type": "string",
24
- "format": "tid",
25
- "description": "Return operations after this revision. The caller's own sync position; use `cursor` to continue a paginated response."
22
+ "format": "tid"
26
23
  },
27
24
  "limit": {
28
25
  "type": "integer",
29
26
  "minimum": 1,
30
27
  "maximum": 1000,
31
- "default": 100,
32
- "description": "Maximum number of operations to return."
28
+ "default": 100
33
29
  },
34
30
  "cursor": {
35
- "type": "string",
36
- "description": "Opaque pagination cursor from a previous response. Takes precedence over `since` when both are supplied."
31
+ "type": "string"
37
32
  },
38
33
  "excludeValues": {
39
34
  "type": "boolean",
40
- "default": false,
41
- "description": "If true, omit inlined record values and return only operation metadata."
35
+ "default": false
42
36
  }
43
37
  }
44
38
  },
@@ -46,7 +40,7 @@
46
40
  "encoding": "application/json",
47
41
  "schema": {
48
42
  "type": "object",
49
- "required": ["ops"],
43
+ "required": ["ops", "commit"],
50
44
  "properties": {
51
45
  "ops": {
52
46
  "type": "array",
@@ -57,27 +51,31 @@
57
51
  },
58
52
  "commit": {
59
53
  "type": "ref",
60
- "ref": "com.atproto.space.defs#signedCommit",
61
- "description": "The account's current signed commit. Included when the response reaches the head of the oplog; omitted on backfill responses."
54
+ "ref": "com.atproto.space.defs#commit",
55
+ "description": "The repo's current commit. A syncer compares it against its own set hash once it has applied the last page, which has no cursor."
62
56
  },
63
57
  "cursor": {
64
- "type": "string",
65
- "description": "Pass as `cursor` to fetch the next page. Absent once the response reaches the head of the oplog."
58
+ "type": "string"
66
59
  }
67
60
  }
68
61
  }
69
62
  },
70
63
  "errors": [
64
+ {
65
+ "name": "InvalidSpaceMac",
66
+ "description": "The MAC requested in the Accept-Signature header is missing or invalid."
67
+ },
71
68
  { "name": "SpaceNotFound" },
72
69
  { "name": "RepoNotFound" },
73
70
  { "name": "RepoTakendown" },
74
71
  { "name": "RepoSuspended" },
75
- { "name": "RepoDeactivated" }
72
+ { "name": "RepoDeactivated" },
73
+ { "name": "InvalidCursor" }
76
74
  ]
77
75
  },
78
76
  "opEntry": {
79
77
  "type": "object",
80
- "description": "A single operation in a permissioned repo's oplog. cid is null for deletes; prev is null for creates. Operations sharing the same rev belong to the same batch. value carries the record's current value for creates and updates, unless excludeValues was set or the value is stale (superseded by a later operation).",
78
+ "description": "Operations that share a rev were applied in the same commit.",
81
79
  "required": ["rev", "collection", "rkey", "cid", "prev"],
82
80
  "nullable": ["cid", "prev"],
83
81
  "properties": {
@@ -95,15 +93,17 @@
95
93
  },
96
94
  "cid": {
97
95
  "type": "string",
98
- "format": "cid"
96
+ "format": "cid",
97
+ "description": "CID of the record after the operation. Null for deletes."
99
98
  },
100
99
  "prev": {
101
100
  "type": "string",
102
- "format": "cid"
101
+ "format": "cid",
102
+ "description": "CID of the record before the operation. Null for creates."
103
103
  },
104
104
  "value": {
105
105
  "type": "unknown",
106
- "description": "The record's current value, inlined for create and update operations. Omitted when excludeValues is set, for deletes, or when the value has been superseded by a later operation."
106
+ "description": "Omitted for deletes, if excludeValues is set, or if the record has since changed."
107
107
  }
108
108
  }
109
109
  }
@@ -4,26 +4,24 @@
4
4
  "defs": {
5
5
  "main": {
6
6
  "type": "query",
7
- "description": "List the spaces the authenticated user holds a repo in (i.e. spaces the user has written data to), optionally filtered by type and/or authority DID. Note this is not 'spaces I'm a member of' — a member's PDS only tracks spaces its user has written to. Requires auth, implemented by PDS.",
7
+ "description": "List spaces that the authenticated account has written to or is the authority for. Requires auth, implemented by PDS.",
8
8
  "parameters": {
9
9
  "type": "params",
10
10
  "properties": {
11
- "type": {
11
+ "spaceDid": {
12
12
  "type": "string",
13
- "format": "nsid",
14
- "description": "Filter to spaces of this type."
13
+ "format": "did",
14
+ "description": "Filter to spaces with this DID as their authority."
15
15
  },
16
- "did": {
16
+ "spaceType": {
17
17
  "type": "string",
18
- "format": "did",
19
- "description": "Filter to spaces under this authority DID."
18
+ "format": "nsid"
20
19
  },
21
20
  "limit": {
22
21
  "type": "integer",
23
22
  "minimum": 1,
24
23
  "maximum": 100,
25
- "default": 50,
26
- "description": "The number of spaces to return."
24
+ "default": 50
27
25
  },
28
26
  "cursor": {
29
27
  "type": "string"
@@ -48,16 +46,34 @@
48
46
  }
49
47
  }
50
48
  }
51
- }
49
+ },
50
+ "errors": [
51
+ {
52
+ "name": "InvalidCursor"
53
+ }
54
+ ]
52
55
  },
53
56
  "spaceView": {
54
57
  "type": "object",
55
- "required": ["uri"],
58
+ "required": ["space"],
56
59
  "properties": {
57
- "uri": {
60
+ "space": {
61
+ "type": "string",
62
+ "format": "space-ref"
63
+ },
64
+ "repoRev": {
65
+ "type": "string",
66
+ "format": "tid",
67
+ "description": "The current revision of the account's repo in the space, if it has one."
68
+ },
69
+ "data": {
70
+ "type": "bytes",
71
+ "description": "The current commit data of the account's repo in the space, if it has one."
72
+ },
73
+ "spaceRev": {
58
74
  "type": "string",
59
- "format": "space-ref",
60
- "description": "URI of the space."
75
+ "format": "tid",
76
+ "description": "The current revision of the space. Only included if the account is the space's authority."
61
77
  }
62
78
  }
63
79
  }
@@ -0,0 +1,66 @@
1
+ {
2
+ "lexicon": 1,
3
+ "id": "com.atproto.space.listWriters",
4
+ "defs": {
5
+ "main": {
6
+ "type": "query",
7
+ "description": "List the repos in a space's writer set, with the latest known state of each: its current revision, or its removal from the writer set. Requires a space credential, implemented by the space host.",
8
+ "parameters": {
9
+ "type": "params",
10
+ "required": ["space"],
11
+ "properties": {
12
+ "space": {
13
+ "type": "string",
14
+ "format": "space-ref"
15
+ },
16
+ "limit": {
17
+ "type": "integer",
18
+ "minimum": 1,
19
+ "maximum": 1000,
20
+ "default": 100
21
+ },
22
+ "cursor": {
23
+ "type": "string",
24
+ "description": "Return repos updated after this space revision. Removed repos may be garbage collected after 72 hrs, so a syncer whose last seen space revision is older should list the whole writer set instead."
25
+ }
26
+ }
27
+ },
28
+ "output": {
29
+ "encoding": "application/json",
30
+ "schema": {
31
+ "type": "object",
32
+ "required": ["repos"],
33
+ "properties": {
34
+ "repos": {
35
+ "type": "array",
36
+ "items": {
37
+ "type": "union",
38
+ "refs": [
39
+ "com.atproto.space.defs#repoWrite",
40
+ "com.atproto.space.defs#repoRemoved"
41
+ ]
42
+ },
43
+ "description": "The latest update to each repo, ordered by spaceRev, ascending. prevSpaceRev is not set."
44
+ },
45
+ "cursor": {
46
+ "type": "string"
47
+ }
48
+ }
49
+ }
50
+ },
51
+ "errors": [
52
+ {
53
+ "name": "SpaceNotFound"
54
+ },
55
+ {
56
+ "name": "RepoTakendown",
57
+ "description": "The space authority has been taken down."
58
+ },
59
+ {
60
+ "name": "RepoDeactivated",
61
+ "description": "The space authority has been deactivated."
62
+ }
63
+ ]
64
+ }
65
+ }
66
+ }
@@ -0,0 +1,30 @@
1
+ {
2
+ "lexicon": 1,
3
+ "id": "com.atproto.space.notifyCredentialsRevoked",
4
+ "defs": {
5
+ "main": {
6
+ "type": "procedure",
7
+ "description": "Notify a repo host that space credentials have been revoked. Sent by the space host. Requires service auth, implemented by PDS.",
8
+ "input": {
9
+ "encoding": "application/json",
10
+ "schema": {
11
+ "type": "object",
12
+ "required": ["space", "credentials"],
13
+ "properties": {
14
+ "space": {
15
+ "type": "string",
16
+ "format": "space-ref"
17
+ },
18
+ "credentials": {
19
+ "type": "array",
20
+ "minLength": 1,
21
+ "maxLength": 100,
22
+ "description": "The IDs (jti) of the revoked credentials.",
23
+ "items": { "type": "string", "minLength": 1 }
24
+ }
25
+ }
26
+ }
27
+ }
28
+ }
29
+ }
30
+ }
@@ -0,0 +1,44 @@
1
+ {
2
+ "lexicon": 1,
3
+ "id": "com.atproto.space.notifyRepoUpdate",
4
+ "defs": {
5
+ "main": {
6
+ "type": "procedure",
7
+ "description": "Notify the space host that a space repo has been updated. Sent by repo hosts, with service auth.",
8
+ "input": {
9
+ "encoding": "application/json",
10
+ "schema": {
11
+ "type": "object",
12
+ "required": ["space", "repo", "repoRev", "data"],
13
+ "properties": {
14
+ "space": {
15
+ "type": "string",
16
+ "format": "space-ref"
17
+ },
18
+ "repo": {
19
+ "type": "string",
20
+ "format": "did"
21
+ },
22
+ "repoRev": {
23
+ "type": "string",
24
+ "format": "tid"
25
+ },
26
+ "data": {
27
+ "type": "bytes",
28
+ "description": "SHA-256 digest of the repo's LtHash state."
29
+ }
30
+ }
31
+ }
32
+ },
33
+ "errors": [
34
+ {
35
+ "name": "SpaceNotFound"
36
+ },
37
+ {
38
+ "name": "FutureRev",
39
+ "description": "The repo revision is too far in the future."
40
+ }
41
+ ]
42
+ }
43
+ }
44
+ }