@atproto/api 0.32.9 → 0.32.11

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 (170) hide show
  1. package/CHANGELOG.md +17 -0
  2. package/dist/client/index.d.ts +177 -0
  3. package/dist/client/index.d.ts.map +1 -1
  4. package/dist/client/index.js +373 -0
  5. package/dist/client/index.js.map +1 -1
  6. package/dist/client/lexicons.d.ts +8583 -4697
  7. package/dist/client/lexicons.d.ts.map +1 -1
  8. package/dist/client/lexicons.js +2135 -0
  9. package/dist/client/lexicons.js.map +1 -1
  10. package/dist/client/types/com/atproto/managedspace/checkAccess.d.ts +26 -0
  11. package/dist/client/types/com/atproto/managedspace/checkAccess.d.ts.map +1 -0
  12. package/dist/client/types/com/atproto/managedspace/checkAccess.js +14 -0
  13. package/dist/client/types/com/atproto/managedspace/checkAccess.js.map +1 -0
  14. package/dist/client/types/com/atproto/managedspace/policy.d.ts +15 -0
  15. package/dist/client/types/com/atproto/managedspace/policy.d.ts.map +1 -0
  16. package/dist/client/types/com/atproto/managedspace/policy.js +17 -0
  17. package/dist/client/types/com/atproto/managedspace/policy.js.map +1 -0
  18. package/dist/client/types/com/atproto/memberspace/defs.d.ts +13 -0
  19. package/dist/client/types/com/atproto/memberspace/defs.d.ts.map +1 -0
  20. package/dist/client/types/com/atproto/memberspace/defs.js +17 -0
  21. package/dist/client/types/com/atproto/memberspace/defs.js.map +1 -0
  22. package/dist/client/types/com/atproto/memberspace/listMembers.d.ts +38 -0
  23. package/dist/client/types/com/atproto/memberspace/listMembers.d.ts.map +1 -0
  24. package/dist/client/types/com/atproto/memberspace/listMembers.js +44 -0
  25. package/dist/client/types/com/atproto/memberspace/listMembers.js.map +1 -0
  26. package/dist/client/types/com/atproto/memberspace/member.d.ts +14 -0
  27. package/dist/client/types/com/atproto/memberspace/member.d.ts.map +1 -0
  28. package/dist/client/types/com/atproto/memberspace/member.js +18 -0
  29. package/dist/client/types/com/atproto/memberspace/member.js.map +1 -0
  30. package/dist/client/types/com/atproto/memberspace/policy.d.ts +21 -0
  31. package/dist/client/types/com/atproto/memberspace/policy.d.ts.map +1 -0
  32. package/dist/client/types/com/atproto/memberspace/policy.js +17 -0
  33. package/dist/client/types/com/atproto/memberspace/policy.js.map +1 -0
  34. package/dist/client/types/com/atproto/memberspace/putMembers.d.ts +31 -0
  35. package/dist/client/types/com/atproto/memberspace/putMembers.d.ts.map +1 -0
  36. package/dist/client/types/com/atproto/memberspace/putMembers.js +37 -0
  37. package/dist/client/types/com/atproto/memberspace/putMembers.js.map +1 -0
  38. package/dist/client/types/com/atproto/memberspace/removeMembers.d.ts +30 -0
  39. package/dist/client/types/com/atproto/memberspace/removeMembers.d.ts.map +1 -0
  40. package/dist/client/types/com/atproto/memberspace/removeMembers.js +37 -0
  41. package/dist/client/types/com/atproto/memberspace/removeMembers.js.map +1 -0
  42. package/dist/client/types/com/atproto/personalspace/policy.d.ts +11 -0
  43. package/dist/client/types/com/atproto/personalspace/policy.d.ts.map +1 -0
  44. package/dist/client/types/com/atproto/personalspace/policy.js +17 -0
  45. package/dist/client/types/com/atproto/personalspace/policy.js.map +1 -0
  46. package/dist/client/types/com/atproto/space/applyWrites.d.ts +90 -0
  47. package/dist/client/types/com/atproto/space/applyWrites.d.ts.map +1 -0
  48. package/dist/client/types/com/atproto/space/applyWrites.js +79 -0
  49. package/dist/client/types/com/atproto/space/applyWrites.js.map +1 -0
  50. package/dist/client/types/com/atproto/space/authorizeSpaceSync.d.ts +72 -0
  51. package/dist/client/types/com/atproto/space/authorizeSpaceSync.d.ts.map +1 -0
  52. package/dist/client/types/com/atproto/space/authorizeSpaceSync.js +93 -0
  53. package/dist/client/types/com/atproto/space/authorizeSpaceSync.js.map +1 -0
  54. package/dist/client/types/com/atproto/space/clearRecords.d.ts +24 -0
  55. package/dist/client/types/com/atproto/space/clearRecords.d.ts.map +1 -0
  56. package/dist/client/types/com/atproto/space/clearRecords.js +14 -0
  57. package/dist/client/types/com/atproto/space/clearRecords.js.map +1 -0
  58. package/dist/client/types/com/atproto/space/confirmRegistration.d.ts +26 -0
  59. package/dist/client/types/com/atproto/space/confirmRegistration.d.ts.map +1 -0
  60. package/dist/client/types/com/atproto/space/confirmRegistration.js +14 -0
  61. package/dist/client/types/com/atproto/space/confirmRegistration.js.map +1 -0
  62. package/dist/client/types/com/atproto/space/createRecord.d.ts +41 -0
  63. package/dist/client/types/com/atproto/space/createRecord.d.ts.map +1 -0
  64. package/dist/client/types/com/atproto/space/createRecord.js +30 -0
  65. package/dist/client/types/com/atproto/space/createRecord.js.map +1 -0
  66. package/dist/client/types/com/atproto/space/createSpace.d.ts +39 -0
  67. package/dist/client/types/com/atproto/space/createSpace.d.ts.map +1 -0
  68. package/dist/client/types/com/atproto/space/createSpace.js +30 -0
  69. package/dist/client/types/com/atproto/space/createSpace.js.map +1 -0
  70. package/dist/client/types/com/atproto/space/defs.d.ts +43 -0
  71. package/dist/client/types/com/atproto/space/defs.d.ts.map +1 -0
  72. package/dist/client/types/com/atproto/space/defs.js +31 -0
  73. package/dist/client/types/com/atproto/space/defs.js.map +1 -0
  74. package/dist/client/types/com/atproto/space/deleteRecord.d.ts +29 -0
  75. package/dist/client/types/com/atproto/space/deleteRecord.d.ts.map +1 -0
  76. package/dist/client/types/com/atproto/space/deleteRecord.js +23 -0
  77. package/dist/client/types/com/atproto/space/deleteRecord.js.map +1 -0
  78. package/dist/client/types/com/atproto/space/deleteSpace.d.ts +26 -0
  79. package/dist/client/types/com/atproto/space/deleteSpace.d.ts.map +1 -0
  80. package/dist/client/types/com/atproto/space/deleteSpace.js +30 -0
  81. package/dist/client/types/com/atproto/space/deleteSpace.js.map +1 -0
  82. package/dist/client/types/com/atproto/space/exportSpaceMeta.d.ts +25 -0
  83. package/dist/client/types/com/atproto/space/exportSpaceMeta.d.ts.map +1 -0
  84. package/dist/client/types/com/atproto/space/exportSpaceMeta.js +30 -0
  85. package/dist/client/types/com/atproto/space/exportSpaceMeta.js.map +1 -0
  86. package/dist/client/types/com/atproto/space/getBlob.d.ts +39 -0
  87. package/dist/client/types/com/atproto/space/getBlob.d.ts.map +1 -0
  88. package/dist/client/types/com/atproto/space/getBlob.js +58 -0
  89. package/dist/client/types/com/atproto/space/getBlob.js.map +1 -0
  90. package/dist/client/types/com/atproto/space/getDelegationToken.d.ts +22 -0
  91. package/dist/client/types/com/atproto/space/getDelegationToken.d.ts.map +1 -0
  92. package/dist/client/types/com/atproto/space/getDelegationToken.js +14 -0
  93. package/dist/client/types/com/atproto/space/getDelegationToken.js.map +1 -0
  94. package/dist/client/types/com/atproto/space/getLatestCommit.d.ts +42 -0
  95. package/dist/client/types/com/atproto/space/getLatestCommit.d.ts.map +1 -0
  96. package/dist/client/types/com/atproto/space/getLatestCommit.js +58 -0
  97. package/dist/client/types/com/atproto/space/getLatestCommit.js.map +1 -0
  98. package/dist/client/types/com/atproto/space/getRecord.d.ts +50 -0
  99. package/dist/client/types/com/atproto/space/getRecord.d.ts.map +1 -0
  100. package/dist/client/types/com/atproto/space/getRecord.js +65 -0
  101. package/dist/client/types/com/atproto/space/getRecord.js.map +1 -0
  102. package/dist/client/types/com/atproto/space/getRepo.d.ts +38 -0
  103. package/dist/client/types/com/atproto/space/getRepo.d.ts.map +1 -0
  104. package/dist/client/types/com/atproto/space/getRepo.js +58 -0
  105. package/dist/client/types/com/atproto/space/getRepo.js.map +1 -0
  106. package/dist/client/types/com/atproto/space/getSpace.d.ts +35 -0
  107. package/dist/client/types/com/atproto/space/getSpace.d.ts.map +1 -0
  108. package/dist/client/types/com/atproto/space/getSpace.js +30 -0
  109. package/dist/client/types/com/atproto/space/getSpace.js.map +1 -0
  110. package/dist/client/types/com/atproto/space/importRepo.d.ts +27 -0
  111. package/dist/client/types/com/atproto/space/importRepo.d.ts.map +1 -0
  112. package/dist/client/types/com/atproto/space/importRepo.js +37 -0
  113. package/dist/client/types/com/atproto/space/importRepo.js.map +1 -0
  114. package/dist/client/types/com/atproto/space/importSpaceMeta.d.ts +27 -0
  115. package/dist/client/types/com/atproto/space/importSpaceMeta.d.ts.map +1 -0
  116. package/dist/client/types/com/atproto/space/importSpaceMeta.js +37 -0
  117. package/dist/client/types/com/atproto/space/importSpaceMeta.js.map +1 -0
  118. package/dist/client/types/com/atproto/space/listBlobs.d.ts +41 -0
  119. package/dist/client/types/com/atproto/space/listBlobs.d.ts.map +1 -0
  120. package/dist/client/types/com/atproto/space/listBlobs.js +51 -0
  121. package/dist/client/types/com/atproto/space/listBlobs.js.map +1 -0
  122. package/dist/client/types/com/atproto/space/listRecords.d.ts +59 -0
  123. package/dist/client/types/com/atproto/space/listRecords.d.ts.map +1 -0
  124. package/dist/client/types/com/atproto/space/listRecords.js +65 -0
  125. package/dist/client/types/com/atproto/space/listRecords.js.map +1 -0
  126. package/dist/client/types/com/atproto/space/listRepoOps.d.ts +69 -0
  127. package/dist/client/types/com/atproto/space/listRepoOps.d.ts.map +1 -0
  128. package/dist/client/types/com/atproto/space/listRepoOps.js +72 -0
  129. package/dist/client/types/com/atproto/space/listRepoOps.js.map +1 -0
  130. package/dist/client/types/com/atproto/space/listSpaces.d.ts +43 -0
  131. package/dist/client/types/com/atproto/space/listSpaces.d.ts.map +1 -0
  132. package/dist/client/types/com/atproto/space/listSpaces.js +30 -0
  133. package/dist/client/types/com/atproto/space/listSpaces.js.map +1 -0
  134. package/dist/client/types/com/atproto/space/listWriters.d.ts +40 -0
  135. package/dist/client/types/com/atproto/space/listWriters.d.ts.map +1 -0
  136. package/dist/client/types/com/atproto/space/listWriters.js +37 -0
  137. package/dist/client/types/com/atproto/space/listWriters.js.map +1 -0
  138. package/dist/client/types/com/atproto/space/notifyCredentialsRevoked.d.ts +22 -0
  139. package/dist/client/types/com/atproto/space/notifyCredentialsRevoked.d.ts.map +1 -0
  140. package/dist/client/types/com/atproto/space/notifyCredentialsRevoked.js +14 -0
  141. package/dist/client/types/com/atproto/space/notifyCredentialsRevoked.js.map +1 -0
  142. package/dist/client/types/com/atproto/space/notifyRepoUpdate.d.ts +30 -0
  143. package/dist/client/types/com/atproto/space/notifyRepoUpdate.d.ts.map +1 -0
  144. package/dist/client/types/com/atproto/space/notifyRepoUpdate.js +30 -0
  145. package/dist/client/types/com/atproto/space/notifyRepoUpdate.js.map +1 -0
  146. package/dist/client/types/com/atproto/space/notifySpaceUpdate.d.ts +41 -0
  147. package/dist/client/types/com/atproto/space/notifySpaceUpdate.d.ts.map +1 -0
  148. package/dist/client/types/com/atproto/space/notifySpaceUpdate.js +28 -0
  149. package/dist/client/types/com/atproto/space/notifySpaceUpdate.js.map +1 -0
  150. package/dist/client/types/com/atproto/space/policy.d.ts +19 -0
  151. package/dist/client/types/com/atproto/space/policy.d.ts.map +1 -0
  152. package/dist/client/types/com/atproto/space/policy.js +18 -0
  153. package/dist/client/types/com/atproto/space/policy.js.map +1 -0
  154. package/dist/client/types/com/atproto/space/putRecord.d.ts +37 -0
  155. package/dist/client/types/com/atproto/space/putRecord.d.ts.map +1 -0
  156. package/dist/client/types/com/atproto/space/putRecord.js +23 -0
  157. package/dist/client/types/com/atproto/space/putRecord.js.map +1 -0
  158. package/dist/client/types/com/atproto/space/removeWriter.d.ts +27 -0
  159. package/dist/client/types/com/atproto/space/removeWriter.d.ts.map +1 -0
  160. package/dist/client/types/com/atproto/space/removeWriter.js +30 -0
  161. package/dist/client/types/com/atproto/space/removeWriter.js.map +1 -0
  162. package/dist/client/types/com/atproto/space/updateSpace.d.ts +36 -0
  163. package/dist/client/types/com/atproto/space/updateSpace.d.ts.map +1 -0
  164. package/dist/client/types/com/atproto/space/updateSpace.js +37 -0
  165. package/dist/client/types/com/atproto/space/updateSpace.js.map +1 -0
  166. package/package.json +7 -7
  167. package/dist/age-assurance.test.d.ts +0 -2
  168. package/dist/age-assurance.test.d.ts.map +0 -1
  169. package/dist/age-assurance.test.js +0 -236
  170. package/dist/age-assurance.test.js.map +0 -1
@@ -18559,6 +18559,306 @@ export const schemaDict = {
18559
18559
  },
18560
18560
  },
18561
18561
  },
18562
+ ComAtprotoManagedspaceCheckAccess: {
18563
+ lexicon: 1,
18564
+ id: 'com.atproto.managedspace.checkAccess',
18565
+ defs: {
18566
+ main: {
18567
+ type: 'query',
18568
+ description: "Check an account's read and write access to a managed space. Called by the space host, implemented by the space's managing app. Requires service auth.",
18569
+ parameters: {
18570
+ type: 'params',
18571
+ required: ['space'],
18572
+ properties: {
18573
+ space: {
18574
+ type: 'string',
18575
+ format: 'space-ref',
18576
+ },
18577
+ repo: {
18578
+ type: 'string',
18579
+ format: 'did',
18580
+ },
18581
+ clientId: {
18582
+ type: 'string',
18583
+ format: 'uri',
18584
+ description: 'OAuth client ID of the requesting app, if attested.',
18585
+ },
18586
+ },
18587
+ },
18588
+ output: {
18589
+ encoding: 'application/json',
18590
+ schema: {
18591
+ type: 'object',
18592
+ required: ['read', 'write'],
18593
+ properties: {
18594
+ read: {
18595
+ type: 'boolean',
18596
+ },
18597
+ write: {
18598
+ type: 'boolean',
18599
+ },
18600
+ },
18601
+ },
18602
+ },
18603
+ },
18604
+ },
18605
+ },
18606
+ ComAtprotoManagedspacePolicy: {
18607
+ lexicon: 1,
18608
+ id: 'com.atproto.managedspace.policy',
18609
+ defs: {
18610
+ main: {
18611
+ type: 'object',
18612
+ description: 'Space policy that delegates access decisions to an external app through checkAccess.',
18613
+ required: ['managingApp'],
18614
+ properties: {
18615
+ managingApp: {
18616
+ type: 'string',
18617
+ description: 'The `did#serviceId` reference of the managing app.',
18618
+ },
18619
+ publishPolicy: {
18620
+ type: 'boolean',
18621
+ default: false,
18622
+ description: 'Publish the policy as a com.atproto.space.policy record in the space.',
18623
+ },
18624
+ },
18625
+ },
18626
+ },
18627
+ },
18628
+ ComAtprotoMemberspaceDefs: {
18629
+ lexicon: 1,
18630
+ id: 'com.atproto.memberspace.defs',
18631
+ defs: {
18632
+ member: {
18633
+ type: 'object',
18634
+ required: ['did', 'read', 'write'],
18635
+ properties: {
18636
+ did: {
18637
+ type: 'string',
18638
+ format: 'did',
18639
+ },
18640
+ read: {
18641
+ type: 'boolean',
18642
+ },
18643
+ write: {
18644
+ type: 'boolean',
18645
+ },
18646
+ },
18647
+ },
18648
+ },
18649
+ },
18650
+ ComAtprotoMemberspaceListMembers: {
18651
+ lexicon: 1,
18652
+ id: 'com.atproto.memberspace.listMembers',
18653
+ defs: {
18654
+ main: {
18655
+ type: 'query',
18656
+ description: 'List the members of a space with a memberspace policy. Requires auth as the space authority, implemented by PDS.',
18657
+ parameters: {
18658
+ type: 'params',
18659
+ required: ['space'],
18660
+ properties: {
18661
+ space: {
18662
+ type: 'string',
18663
+ format: 'space-ref',
18664
+ },
18665
+ limit: {
18666
+ type: 'integer',
18667
+ minimum: 1,
18668
+ maximum: 1000,
18669
+ default: 100,
18670
+ },
18671
+ cursor: {
18672
+ type: 'string',
18673
+ },
18674
+ },
18675
+ },
18676
+ output: {
18677
+ encoding: 'application/json',
18678
+ schema: {
18679
+ type: 'object',
18680
+ required: ['members'],
18681
+ properties: {
18682
+ cursor: {
18683
+ type: 'string',
18684
+ },
18685
+ members: {
18686
+ type: 'array',
18687
+ items: {
18688
+ type: 'ref',
18689
+ ref: 'lex:com.atproto.memberspace.defs#member',
18690
+ },
18691
+ },
18692
+ },
18693
+ },
18694
+ },
18695
+ errors: [
18696
+ {
18697
+ name: 'SpaceNotFound',
18698
+ },
18699
+ {
18700
+ name: 'NotAuthorized',
18701
+ },
18702
+ {
18703
+ name: 'PolicyMismatch',
18704
+ description: 'The space does not have a memberspace policy.',
18705
+ },
18706
+ {
18707
+ name: 'InvalidCursor',
18708
+ },
18709
+ ],
18710
+ },
18711
+ },
18712
+ },
18713
+ ComAtprotoMemberspaceMember: {
18714
+ lexicon: 1,
18715
+ id: 'com.atproto.memberspace.member',
18716
+ defs: {
18717
+ main: {
18718
+ type: 'record',
18719
+ description: "A published entry in a space's member list, keyed by the member's DID. Only authoritative in the space authority's repo.",
18720
+ key: 'any',
18721
+ record: {
18722
+ type: 'object',
18723
+ required: ['read', 'write'],
18724
+ properties: {
18725
+ read: {
18726
+ type: 'boolean',
18727
+ },
18728
+ write: {
18729
+ type: 'boolean',
18730
+ },
18731
+ },
18732
+ },
18733
+ },
18734
+ },
18735
+ },
18736
+ ComAtprotoMemberspacePolicy: {
18737
+ lexicon: 1,
18738
+ id: 'com.atproto.memberspace.policy',
18739
+ defs: {
18740
+ main: {
18741
+ type: 'object',
18742
+ description: 'Space policy that grants access based on a member list.',
18743
+ properties: {
18744
+ publicRead: {
18745
+ type: 'boolean',
18746
+ default: false,
18747
+ description: 'If true, anyone may read the space. Otherwise, only members with read access.',
18748
+ },
18749
+ publicWrite: {
18750
+ type: 'boolean',
18751
+ default: false,
18752
+ description: "If true, any account's writes are tracked in the writer set, except members without write access. Otherwise, only members with write access.",
18753
+ },
18754
+ allowedApps: {
18755
+ type: 'array',
18756
+ description: 'If set, only these apps (by OAuth client ID) may read the space.',
18757
+ items: {
18758
+ type: 'string',
18759
+ format: 'uri',
18760
+ },
18761
+ },
18762
+ publishPolicy: {
18763
+ type: 'boolean',
18764
+ default: false,
18765
+ description: 'Publish the policy as a com.atproto.space.policy record in the space.',
18766
+ },
18767
+ publishMembers: {
18768
+ type: 'boolean',
18769
+ default: false,
18770
+ description: 'Publish the member list as com.atproto.memberspace.member records in the space.',
18771
+ },
18772
+ },
18773
+ },
18774
+ },
18775
+ },
18776
+ ComAtprotoMemberspacePutMembers: {
18777
+ lexicon: 1,
18778
+ id: 'com.atproto.memberspace.putMembers',
18779
+ defs: {
18780
+ main: {
18781
+ type: 'procedure',
18782
+ description: "Add members to a space, or update existing members' access, in a single commit. Requires auth as the space authority, implemented by PDS.",
18783
+ input: {
18784
+ encoding: 'application/json',
18785
+ schema: {
18786
+ type: 'object',
18787
+ required: ['space', 'members'],
18788
+ properties: {
18789
+ space: {
18790
+ type: 'string',
18791
+ format: 'space-ref',
18792
+ },
18793
+ members: {
18794
+ type: 'array',
18795
+ maxLength: 100,
18796
+ items: {
18797
+ type: 'ref',
18798
+ ref: 'lex:com.atproto.memberspace.defs#member',
18799
+ },
18800
+ },
18801
+ },
18802
+ },
18803
+ },
18804
+ errors: [
18805
+ {
18806
+ name: 'SpaceNotFound',
18807
+ },
18808
+ {
18809
+ name: 'NotAuthorized',
18810
+ },
18811
+ {
18812
+ name: 'PolicyMismatch',
18813
+ description: 'The space does not have a memberspace policy.',
18814
+ },
18815
+ ],
18816
+ },
18817
+ },
18818
+ },
18819
+ ComAtprotoMemberspaceRemoveMembers: {
18820
+ lexicon: 1,
18821
+ id: 'com.atproto.memberspace.removeMembers',
18822
+ defs: {
18823
+ main: {
18824
+ type: 'procedure',
18825
+ description: 'Remove members from a space in a single commit. DIDs that are not members are ignored. Requires auth as the space authority, implemented by PDS.',
18826
+ input: {
18827
+ encoding: 'application/json',
18828
+ schema: {
18829
+ type: 'object',
18830
+ required: ['space', 'dids'],
18831
+ properties: {
18832
+ space: {
18833
+ type: 'string',
18834
+ format: 'space-ref',
18835
+ },
18836
+ dids: {
18837
+ type: 'array',
18838
+ maxLength: 100,
18839
+ items: {
18840
+ type: 'string',
18841
+ format: 'did',
18842
+ },
18843
+ },
18844
+ },
18845
+ },
18846
+ },
18847
+ errors: [
18848
+ {
18849
+ name: 'SpaceNotFound',
18850
+ },
18851
+ {
18852
+ name: 'NotAuthorized',
18853
+ },
18854
+ {
18855
+ name: 'PolicyMismatch',
18856
+ description: 'The space does not have a memberspace policy.',
18857
+ },
18858
+ ],
18859
+ },
18860
+ },
18861
+ },
18562
18862
  ComAtprotoModerationCreateReport: {
18563
18863
  lexicon: 1,
18564
18864
  id: 'com.atproto.moderation.createReport',
@@ -18748,6 +19048,17 @@ export const schemaDict = {
18748
19048
  },
18749
19049
  },
18750
19050
  },
19051
+ ComAtprotoPersonalspacePolicy: {
19052
+ lexicon: 1,
19053
+ id: 'com.atproto.personalspace.policy',
19054
+ defs: {
19055
+ main: {
19056
+ type: 'object',
19057
+ description: 'Space policy for personal data that only the space authority and authorized apps can read, such as bookmarks or drafts.',
19058
+ properties: {},
19059
+ },
19060
+ },
19061
+ },
18751
19062
  ComAtprotoRepoApplyWrites: {
18752
19063
  lexicon: 1,
18753
19064
  id: 'com.atproto.repo.applyWrites',
@@ -20623,6 +20934,1791 @@ export const schemaDict = {
20623
20934
  },
20624
20935
  },
20625
20936
  },
20937
+ ComAtprotoSpaceApplyWrites: {
20938
+ lexicon: 1,
20939
+ id: 'com.atproto.space.applyWrites',
20940
+ defs: {
20941
+ main: {
20942
+ type: 'procedure',
20943
+ description: 'Apply a batch transaction of creates, updates, and deletes to a space repo. Requires auth, implemented by PDS.',
20944
+ input: {
20945
+ encoding: 'application/json',
20946
+ schema: {
20947
+ type: 'object',
20948
+ required: ['space', 'repo', 'writes'],
20949
+ properties: {
20950
+ space: {
20951
+ type: 'string',
20952
+ format: 'space-ref',
20953
+ },
20954
+ repo: {
20955
+ type: 'string',
20956
+ format: 'did',
20957
+ },
20958
+ validate: {
20959
+ type: 'boolean',
20960
+ description: "Can be set to 'false' to skip Lexicon schema validation of record data across all operations, 'true' to require it, or leave unset to validate only for known Lexicons.",
20961
+ },
20962
+ writes: {
20963
+ type: 'array',
20964
+ items: {
20965
+ type: 'union',
20966
+ refs: [
20967
+ 'lex:com.atproto.space.applyWrites#create',
20968
+ 'lex:com.atproto.space.applyWrites#update',
20969
+ 'lex:com.atproto.space.applyWrites#delete',
20970
+ ],
20971
+ closed: true,
20972
+ },
20973
+ },
20974
+ },
20975
+ },
20976
+ },
20977
+ output: {
20978
+ encoding: 'application/json',
20979
+ schema: {
20980
+ type: 'object',
20981
+ properties: {
20982
+ results: {
20983
+ type: 'array',
20984
+ items: {
20985
+ type: 'union',
20986
+ refs: [
20987
+ 'lex:com.atproto.space.applyWrites#createResult',
20988
+ 'lex:com.atproto.space.applyWrites#updateResult',
20989
+ 'lex:com.atproto.space.applyWrites#deleteResult',
20990
+ ],
20991
+ closed: true,
20992
+ },
20993
+ },
20994
+ },
20995
+ },
20996
+ },
20997
+ errors: [
20998
+ {
20999
+ name: 'SpaceNotFound',
21000
+ },
21001
+ {
21002
+ name: 'RecordNotFound',
21003
+ },
21004
+ {
21005
+ name: 'RecordAlreadyExists',
21006
+ },
21007
+ ],
21008
+ },
21009
+ create: {
21010
+ type: 'object',
21011
+ description: 'Operation which creates a new record.',
21012
+ required: ['collection', 'value'],
21013
+ properties: {
21014
+ collection: {
21015
+ type: 'string',
21016
+ format: 'nsid',
21017
+ },
21018
+ rkey: {
21019
+ type: 'string',
21020
+ format: 'record-key',
21021
+ },
21022
+ value: {
21023
+ type: 'unknown',
21024
+ },
21025
+ },
21026
+ },
21027
+ update: {
21028
+ type: 'object',
21029
+ description: 'Operation which updates an existing record.',
21030
+ required: ['collection', 'rkey', 'value'],
21031
+ properties: {
21032
+ collection: {
21033
+ type: 'string',
21034
+ format: 'nsid',
21035
+ },
21036
+ rkey: {
21037
+ type: 'string',
21038
+ format: 'record-key',
21039
+ },
21040
+ value: {
21041
+ type: 'unknown',
21042
+ },
21043
+ },
21044
+ },
21045
+ delete: {
21046
+ type: 'object',
21047
+ description: 'Operation which deletes an existing record.',
21048
+ required: ['collection', 'rkey'],
21049
+ properties: {
21050
+ collection: {
21051
+ type: 'string',
21052
+ format: 'nsid',
21053
+ },
21054
+ rkey: {
21055
+ type: 'string',
21056
+ format: 'record-key',
21057
+ },
21058
+ },
21059
+ },
21060
+ createResult: {
21061
+ type: 'object',
21062
+ required: ['uri', 'cid'],
21063
+ properties: {
21064
+ uri: {
21065
+ type: 'string',
21066
+ format: 'at-uri',
21067
+ },
21068
+ cid: {
21069
+ type: 'string',
21070
+ format: 'cid',
21071
+ },
21072
+ validationStatus: {
21073
+ type: 'string',
21074
+ knownValues: ['valid', 'unknown'],
21075
+ },
21076
+ },
21077
+ },
21078
+ updateResult: {
21079
+ type: 'object',
21080
+ required: ['uri', 'cid'],
21081
+ properties: {
21082
+ uri: {
21083
+ type: 'string',
21084
+ format: 'at-uri',
21085
+ },
21086
+ cid: {
21087
+ type: 'string',
21088
+ format: 'cid',
21089
+ },
21090
+ validationStatus: {
21091
+ type: 'string',
21092
+ knownValues: ['valid', 'unknown'],
21093
+ },
21094
+ },
21095
+ },
21096
+ deleteResult: {
21097
+ type: 'object',
21098
+ required: [],
21099
+ properties: {},
21100
+ },
21101
+ },
21102
+ },
21103
+ ComAtprotoSpaceAuthorizeSpaceSync: {
21104
+ lexicon: 1,
21105
+ id: 'com.atproto.space.authorizeSpaceSync',
21106
+ defs: {
21107
+ main: {
21108
+ type: 'procedure',
21109
+ description: "Authorize syncing a space, returning a new credential for reading data across it and the space's current revision, and optionally registering for notifications of updates to it. Depending on the space's policy, a delegation token and/or client attestation may be required. Implemented by the space host.",
21110
+ input: {
21111
+ encoding: 'application/json',
21112
+ schema: {
21113
+ type: 'object',
21114
+ required: ['space', 'credentialKey'],
21115
+ properties: {
21116
+ space: {
21117
+ type: 'string',
21118
+ format: 'space-ref',
21119
+ },
21120
+ credentialKey: {
21121
+ type: 'string',
21122
+ description: 'P-256 did:key that the credential is bound to.',
21123
+ },
21124
+ delegationToken: {
21125
+ type: 'string',
21126
+ description: 'Obtained from getDelegationToken.',
21127
+ },
21128
+ clientAttestation: {
21129
+ type: 'string',
21130
+ },
21131
+ notify: {
21132
+ type: 'ref',
21133
+ ref: 'lex:com.atproto.space.authorizeSpaceSync#notify',
21134
+ description: "Register an endpoint to be notified of updates to the space via notifySpaceUpdate. The registration stays active while this credential is valid. After it expires, the endpoint receives only a prompt to reauthorize, or notice of the space's deletion.",
21135
+ },
21136
+ },
21137
+ },
21138
+ },
21139
+ output: {
21140
+ encoding: 'application/json',
21141
+ schema: {
21142
+ type: 'object',
21143
+ required: ['credential'],
21144
+ properties: {
21145
+ credential: {
21146
+ type: 'string',
21147
+ },
21148
+ spaceRev: {
21149
+ type: 'string',
21150
+ format: 'tid',
21151
+ description: "The space's current revision. Omitted before the space's first update.",
21152
+ },
21153
+ },
21154
+ },
21155
+ },
21156
+ errors: [
21157
+ {
21158
+ name: 'SpaceNotFound',
21159
+ description: 'May also be returned in place of AccountNotAuthorized, to avoid revealing that the space exists.',
21160
+ },
21161
+ {
21162
+ name: 'SpaceDeleted',
21163
+ },
21164
+ {
21165
+ name: 'AccountNotAuthorized',
21166
+ },
21167
+ {
21168
+ name: 'AppNotAuthorized',
21169
+ },
21170
+ {
21171
+ name: 'NotAuthorized',
21172
+ description: 'Generic refusal. May be returned in place of AccountNotAuthorized or AppNotAuthorized.',
21173
+ },
21174
+ {
21175
+ name: 'InvalidDelegationToken',
21176
+ },
21177
+ {
21178
+ name: 'InvalidClientAttestation',
21179
+ },
21180
+ {
21181
+ name: 'RegistrationNotConfirmed',
21182
+ description: 'The notify endpoint did not confirm the registration.',
21183
+ },
21184
+ {
21185
+ name: 'RepoTakendown',
21186
+ description: 'The space authority has been taken down.',
21187
+ },
21188
+ {
21189
+ name: 'RepoDeactivated',
21190
+ description: 'The space authority has been deactivated.',
21191
+ },
21192
+ ],
21193
+ },
21194
+ notify: {
21195
+ type: 'object',
21196
+ required: ['endpoint', 'token'],
21197
+ properties: {
21198
+ endpoint: {
21199
+ type: 'string',
21200
+ format: 'uri',
21201
+ description: 'Base HTTPS URL that notification methods are called against.',
21202
+ },
21203
+ token: {
21204
+ type: 'string',
21205
+ maxLength: 512,
21206
+ description: 'Opaque secret, included in the body of each request to the endpoint. The endpoint and token together identify the registration, so the token should stay the same across authorizations.',
21207
+ },
21208
+ },
21209
+ },
21210
+ },
21211
+ },
21212
+ ComAtprotoSpaceClearRecords: {
21213
+ lexicon: 1,
21214
+ id: 'com.atproto.space.clearRecords',
21215
+ defs: {
21216
+ main: {
21217
+ type: 'procedure',
21218
+ description: "Delete all records in the authenticated account's space repo. In the space authority's repo, records published from the space's configuration (such as its policy) are kept. Requires auth, implemented by PDS.",
21219
+ input: {
21220
+ encoding: 'application/json',
21221
+ schema: {
21222
+ type: 'object',
21223
+ required: ['space', 'repo'],
21224
+ properties: {
21225
+ space: {
21226
+ type: 'string',
21227
+ format: 'space-ref',
21228
+ },
21229
+ repo: {
21230
+ type: 'string',
21231
+ format: 'did',
21232
+ },
21233
+ },
21234
+ },
21235
+ },
21236
+ output: {
21237
+ encoding: 'application/json',
21238
+ schema: {
21239
+ type: 'object',
21240
+ properties: {},
21241
+ },
21242
+ },
21243
+ },
21244
+ },
21245
+ },
21246
+ ComAtprotoSpaceConfirmRegistration: {
21247
+ lexicon: 1,
21248
+ id: 'com.atproto.space.confirmRegistration',
21249
+ defs: {
21250
+ main: {
21251
+ type: 'procedure',
21252
+ description: 'Confirm a new notification registration. Called by the space host on an endpoint passed to authorizeSpaceSync, before registering it. The syncing service checks that it issued the token for the space, and echoes back the challenge.',
21253
+ input: {
21254
+ encoding: 'application/json',
21255
+ schema: {
21256
+ type: 'object',
21257
+ required: ['space', 'token', 'challenge'],
21258
+ properties: {
21259
+ space: {
21260
+ type: 'string',
21261
+ format: 'space-ref',
21262
+ },
21263
+ token: {
21264
+ type: 'string',
21265
+ maxLength: 512,
21266
+ },
21267
+ challenge: {
21268
+ type: 'string',
21269
+ maxLength: 512,
21270
+ },
21271
+ },
21272
+ },
21273
+ },
21274
+ output: {
21275
+ encoding: 'application/json',
21276
+ schema: {
21277
+ type: 'object',
21278
+ required: ['challenge'],
21279
+ properties: {
21280
+ challenge: {
21281
+ type: 'string',
21282
+ maxLength: 512,
21283
+ },
21284
+ },
21285
+ },
21286
+ },
21287
+ },
21288
+ },
21289
+ },
21290
+ ComAtprotoSpaceCreateRecord: {
21291
+ lexicon: 1,
21292
+ id: 'com.atproto.space.createRecord',
21293
+ defs: {
21294
+ main: {
21295
+ type: 'procedure',
21296
+ description: 'Create a single new record in a space repo. Requires auth, implemented by PDS.',
21297
+ input: {
21298
+ encoding: 'application/json',
21299
+ schema: {
21300
+ type: 'object',
21301
+ required: ['space', 'repo', 'collection', 'record'],
21302
+ properties: {
21303
+ space: {
21304
+ type: 'string',
21305
+ format: 'space-ref',
21306
+ },
21307
+ repo: {
21308
+ type: 'string',
21309
+ format: 'did',
21310
+ },
21311
+ collection: {
21312
+ type: 'string',
21313
+ format: 'nsid',
21314
+ },
21315
+ rkey: {
21316
+ type: 'string',
21317
+ format: 'record-key',
21318
+ },
21319
+ validate: {
21320
+ type: 'boolean',
21321
+ description: "Can be set to 'false' to skip Lexicon schema validation of record data, 'true' to require it, or leave unset to validate only for known Lexicons.",
21322
+ },
21323
+ record: {
21324
+ type: 'unknown',
21325
+ description: 'The record itself. Must contain a $type field.',
21326
+ },
21327
+ },
21328
+ },
21329
+ },
21330
+ output: {
21331
+ encoding: 'application/json',
21332
+ schema: {
21333
+ type: 'object',
21334
+ required: ['uri', 'cid'],
21335
+ properties: {
21336
+ uri: {
21337
+ type: 'string',
21338
+ format: 'at-uri',
21339
+ },
21340
+ cid: {
21341
+ type: 'string',
21342
+ format: 'cid',
21343
+ },
21344
+ validationStatus: {
21345
+ type: 'string',
21346
+ knownValues: ['valid', 'unknown'],
21347
+ },
21348
+ },
21349
+ },
21350
+ },
21351
+ errors: [
21352
+ {
21353
+ name: 'SpaceNotFound',
21354
+ },
21355
+ {
21356
+ name: 'RecordAlreadyExists',
21357
+ },
21358
+ ],
21359
+ },
21360
+ },
21361
+ },
21362
+ ComAtprotoSpaceCreateSpace: {
21363
+ lexicon: 1,
21364
+ id: 'com.atproto.space.createSpace',
21365
+ defs: {
21366
+ main: {
21367
+ type: 'procedure',
21368
+ description: 'Create a new space, with the authenticated account as its authority. Requires auth, implemented by PDS.',
21369
+ input: {
21370
+ encoding: 'application/json',
21371
+ schema: {
21372
+ type: 'object',
21373
+ required: ['spaceType', 'policy'],
21374
+ properties: {
21375
+ spaceType: {
21376
+ type: 'string',
21377
+ format: 'nsid',
21378
+ },
21379
+ skey: {
21380
+ type: 'string',
21381
+ format: 'record-key',
21382
+ description: 'Space key. Generated as a TID if not provided.',
21383
+ },
21384
+ policy: {
21385
+ type: 'union',
21386
+ 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.',
21387
+ refs: [
21388
+ 'lex:com.atproto.personalspace.policy',
21389
+ 'lex:com.atproto.memberspace.policy',
21390
+ 'lex:com.atproto.managedspace.policy',
21391
+ ],
21392
+ },
21393
+ },
21394
+ },
21395
+ },
21396
+ output: {
21397
+ encoding: 'application/json',
21398
+ schema: {
21399
+ type: 'object',
21400
+ required: ['space'],
21401
+ properties: {
21402
+ space: {
21403
+ type: 'string',
21404
+ format: 'space-ref',
21405
+ },
21406
+ },
21407
+ },
21408
+ },
21409
+ errors: [
21410
+ {
21411
+ name: 'SpaceAlreadyExists',
21412
+ },
21413
+ {
21414
+ name: 'UnsupportedPolicy',
21415
+ },
21416
+ ],
21417
+ },
21418
+ },
21419
+ },
21420
+ ComAtprotoSpaceDefs: {
21421
+ lexicon: 1,
21422
+ id: 'com.atproto.space.defs',
21423
+ defs: {
21424
+ commit: {
21425
+ type: 'object',
21426
+ description: 'Commit to the current state of a space repo. Not signed; authenticated by the repo host with a MAC instead.',
21427
+ required: ['ver', 'repo', 'space', 'rev', 'data'],
21428
+ properties: {
21429
+ ver: {
21430
+ type: 'integer',
21431
+ description: 'Commit format version, currently 1.',
21432
+ },
21433
+ repo: {
21434
+ type: 'string',
21435
+ format: 'did',
21436
+ },
21437
+ space: {
21438
+ type: 'string',
21439
+ format: 'space-ref',
21440
+ },
21441
+ rev: {
21442
+ type: 'string',
21443
+ format: 'tid',
21444
+ },
21445
+ data: {
21446
+ type: 'bytes',
21447
+ description: "SHA-256 digest of the repo's LtHash state.",
21448
+ },
21449
+ },
21450
+ },
21451
+ repoWrite: {
21452
+ type: 'object',
21453
+ description: 'A repo in the space advanced to a new revision.',
21454
+ required: ['repo', 'repoRev', 'data', 'spaceRev'],
21455
+ properties: {
21456
+ repo: {
21457
+ type: 'string',
21458
+ format: 'did',
21459
+ },
21460
+ repoRev: {
21461
+ type: 'string',
21462
+ format: 'tid',
21463
+ },
21464
+ data: {
21465
+ type: 'bytes',
21466
+ description: "SHA-256 digest of the repo's LtHash state.",
21467
+ },
21468
+ spaceRev: {
21469
+ type: 'string',
21470
+ format: 'tid',
21471
+ description: 'The space revision at which this update was sequenced.',
21472
+ },
21473
+ prevSpaceRev: {
21474
+ type: 'string',
21475
+ format: 'tid',
21476
+ description: 'The space revision before this update, if any. Set in notifySpaceUpdate, where a gap indicates missed notifications, which can be recovered with listWriters.',
21477
+ },
21478
+ },
21479
+ },
21480
+ repoRemoved: {
21481
+ type: 'object',
21482
+ description: 'A repo was removed from the writer set.',
21483
+ required: ['repo', 'spaceRev'],
21484
+ properties: {
21485
+ repo: {
21486
+ type: 'string',
21487
+ format: 'did',
21488
+ },
21489
+ spaceRev: {
21490
+ type: 'string',
21491
+ format: 'tid',
21492
+ description: 'The space revision at which this update was sequenced.',
21493
+ },
21494
+ prevSpaceRev: {
21495
+ type: 'string',
21496
+ format: 'tid',
21497
+ description: 'The space revision before this update, if any. Set in notifySpaceUpdate, where a gap indicates missed notifications, which can be recovered with listWriters.',
21498
+ },
21499
+ },
21500
+ },
21501
+ },
21502
+ },
21503
+ ComAtprotoSpaceDeleteRecord: {
21504
+ lexicon: 1,
21505
+ id: 'com.atproto.space.deleteRecord',
21506
+ defs: {
21507
+ main: {
21508
+ type: 'procedure',
21509
+ description: "Delete a record from a space repo, or ensure it doesn't exist. Requires auth, implemented by PDS.",
21510
+ input: {
21511
+ encoding: 'application/json',
21512
+ schema: {
21513
+ type: 'object',
21514
+ required: ['space', 'repo', 'collection', 'rkey'],
21515
+ properties: {
21516
+ space: {
21517
+ type: 'string',
21518
+ format: 'space-ref',
21519
+ },
21520
+ repo: {
21521
+ type: 'string',
21522
+ format: 'did',
21523
+ },
21524
+ collection: {
21525
+ type: 'string',
21526
+ format: 'nsid',
21527
+ },
21528
+ rkey: {
21529
+ type: 'string',
21530
+ format: 'record-key',
21531
+ },
21532
+ },
21533
+ },
21534
+ },
21535
+ output: {
21536
+ encoding: 'application/json',
21537
+ schema: {
21538
+ type: 'object',
21539
+ properties: {},
21540
+ },
21541
+ },
21542
+ errors: [
21543
+ {
21544
+ name: 'SpaceNotFound',
21545
+ },
21546
+ ],
21547
+ },
21548
+ },
21549
+ },
21550
+ ComAtprotoSpaceDeleteSpace: {
21551
+ lexicon: 1,
21552
+ id: 'com.atproto.space.deleteSpace',
21553
+ defs: {
21554
+ main: {
21555
+ type: 'procedure',
21556
+ description: "Delete a space, along with the authority's space repo. Requires auth as the space authority, implemented by PDS.",
21557
+ input: {
21558
+ encoding: 'application/json',
21559
+ schema: {
21560
+ type: 'object',
21561
+ required: ['space'],
21562
+ properties: {
21563
+ space: {
21564
+ type: 'string',
21565
+ format: 'space-ref',
21566
+ },
21567
+ },
21568
+ },
21569
+ },
21570
+ errors: [
21571
+ {
21572
+ name: 'SpaceNotFound',
21573
+ },
21574
+ {
21575
+ name: 'NotAuthorized',
21576
+ },
21577
+ ],
21578
+ },
21579
+ },
21580
+ },
21581
+ ComAtprotoSpaceExportSpaceMeta: {
21582
+ lexicon: 1,
21583
+ id: 'com.atproto.space.exportSpaceMeta',
21584
+ defs: {
21585
+ main: {
21586
+ type: 'query',
21587
+ description: "Export a space's state, such as its policy and member list, as a STAR file for account migration. Requires auth as the space authority, implemented by PDS.",
21588
+ parameters: {
21589
+ type: 'params',
21590
+ required: ['space'],
21591
+ properties: {
21592
+ space: {
21593
+ type: 'string',
21594
+ format: 'space-ref',
21595
+ },
21596
+ },
21597
+ },
21598
+ output: {
21599
+ encoding: 'application/vnd.dasl.star',
21600
+ },
21601
+ errors: [
21602
+ {
21603
+ name: 'SpaceNotFound',
21604
+ },
21605
+ {
21606
+ name: 'NotAuthorized',
21607
+ },
21608
+ ],
21609
+ },
21610
+ },
21611
+ },
21612
+ ComAtprotoSpaceGetBlob: {
21613
+ lexicon: 1,
21614
+ id: 'com.atproto.space.getBlob',
21615
+ defs: {
21616
+ main: {
21617
+ type: 'query',
21618
+ description: "Get a blob referenced by a record in a space repo. Returns the full blob as originally uploaded. Requires auth as the repo's account or with a space credential; implemented by PDS.",
21619
+ parameters: {
21620
+ type: 'params',
21621
+ required: ['space', 'repo', 'cid'],
21622
+ properties: {
21623
+ space: {
21624
+ type: 'string',
21625
+ format: 'space-ref',
21626
+ },
21627
+ repo: {
21628
+ type: 'string',
21629
+ format: 'did',
21630
+ },
21631
+ cid: {
21632
+ type: 'string',
21633
+ format: 'cid',
21634
+ },
21635
+ },
21636
+ },
21637
+ output: {
21638
+ encoding: '*/*',
21639
+ },
21640
+ errors: [
21641
+ {
21642
+ name: 'BlobNotFound',
21643
+ },
21644
+ {
21645
+ name: 'SpaceNotFound',
21646
+ },
21647
+ {
21648
+ name: 'RepoNotFound',
21649
+ },
21650
+ {
21651
+ name: 'RepoTakendown',
21652
+ },
21653
+ {
21654
+ name: 'RepoSuspended',
21655
+ },
21656
+ {
21657
+ name: 'RepoDeactivated',
21658
+ },
21659
+ ],
21660
+ },
21661
+ },
21662
+ },
21663
+ ComAtprotoSpaceGetDelegationToken: {
21664
+ lexicon: 1,
21665
+ id: 'com.atproto.space.getDelegationToken',
21666
+ defs: {
21667
+ main: {
21668
+ type: 'query',
21669
+ description: 'Get a delegation token for a space, to exchange with the space host for a space credential. Requires auth, implemented by PDS.',
21670
+ parameters: {
21671
+ type: 'params',
21672
+ required: ['space'],
21673
+ properties: {
21674
+ space: {
21675
+ type: 'string',
21676
+ format: 'space-ref',
21677
+ },
21678
+ },
21679
+ },
21680
+ output: {
21681
+ encoding: 'application/json',
21682
+ schema: {
21683
+ type: 'object',
21684
+ required: ['token'],
21685
+ properties: {
21686
+ token: {
21687
+ type: 'string',
21688
+ },
21689
+ },
21690
+ },
21691
+ },
21692
+ },
21693
+ },
21694
+ },
21695
+ ComAtprotoSpaceGetLatestCommit: {
21696
+ lexicon: 1,
21697
+ id: 'com.atproto.space.getLatestCommit',
21698
+ defs: {
21699
+ main: {
21700
+ type: 'query',
21701
+ description: "Get the current commit of a space repo. Responses are authenticated with a MAC. Requires auth as the repo's account or with a space credential; implemented by PDS.",
21702
+ parameters: {
21703
+ type: 'params',
21704
+ required: ['space', 'repo'],
21705
+ properties: {
21706
+ space: {
21707
+ type: 'string',
21708
+ format: 'space-ref',
21709
+ },
21710
+ repo: {
21711
+ type: 'string',
21712
+ format: 'did',
21713
+ },
21714
+ },
21715
+ },
21716
+ output: {
21717
+ encoding: 'application/json',
21718
+ schema: {
21719
+ type: 'object',
21720
+ properties: {
21721
+ commit: {
21722
+ type: 'ref',
21723
+ ref: 'lex:com.atproto.space.defs#commit',
21724
+ },
21725
+ },
21726
+ required: ['commit'],
21727
+ },
21728
+ },
21729
+ errors: [
21730
+ {
21731
+ name: 'InvalidSpaceMac',
21732
+ description: 'The MAC requested in the Accept-Signature header is missing or invalid.',
21733
+ },
21734
+ {
21735
+ name: 'SpaceNotFound',
21736
+ },
21737
+ {
21738
+ name: 'RepoNotFound',
21739
+ },
21740
+ {
21741
+ name: 'RepoTakendown',
21742
+ },
21743
+ {
21744
+ name: 'RepoSuspended',
21745
+ },
21746
+ {
21747
+ name: 'RepoDeactivated',
21748
+ },
21749
+ ],
21750
+ },
21751
+ },
21752
+ },
21753
+ ComAtprotoSpaceGetRecord: {
21754
+ lexicon: 1,
21755
+ id: 'com.atproto.space.getRecord',
21756
+ defs: {
21757
+ main: {
21758
+ type: 'query',
21759
+ 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.",
21760
+ parameters: {
21761
+ type: 'params',
21762
+ required: ['space', 'repo', 'collection', 'rkey'],
21763
+ properties: {
21764
+ space: {
21765
+ type: 'string',
21766
+ format: 'space-ref',
21767
+ },
21768
+ repo: {
21769
+ type: 'string',
21770
+ format: 'did',
21771
+ },
21772
+ collection: {
21773
+ type: 'string',
21774
+ format: 'nsid',
21775
+ },
21776
+ rkey: {
21777
+ type: 'string',
21778
+ format: 'record-key',
21779
+ },
21780
+ },
21781
+ },
21782
+ output: {
21783
+ encoding: 'application/json',
21784
+ schema: {
21785
+ type: 'object',
21786
+ required: ['uri', 'cid', 'value'],
21787
+ properties: {
21788
+ uri: {
21789
+ type: 'string',
21790
+ format: 'at-uri',
21791
+ },
21792
+ cid: {
21793
+ type: 'string',
21794
+ format: 'cid',
21795
+ },
21796
+ value: {
21797
+ type: 'unknown',
21798
+ },
21799
+ },
21800
+ },
21801
+ },
21802
+ errors: [
21803
+ {
21804
+ name: 'InvalidSpaceMac',
21805
+ description: 'The MAC requested in the Accept-Signature header is missing or invalid.',
21806
+ },
21807
+ {
21808
+ name: 'RecordNotFound',
21809
+ },
21810
+ {
21811
+ name: 'SpaceNotFound',
21812
+ },
21813
+ {
21814
+ name: 'RepoNotFound',
21815
+ },
21816
+ {
21817
+ name: 'RepoTakendown',
21818
+ },
21819
+ {
21820
+ name: 'RepoSuspended',
21821
+ },
21822
+ {
21823
+ name: 'RepoDeactivated',
21824
+ },
21825
+ ],
21826
+ },
21827
+ },
21828
+ },
21829
+ ComAtprotoSpaceGetRepo: {
21830
+ lexicon: 1,
21831
+ id: 'com.atproto.space.getRepo',
21832
+ defs: {
21833
+ main: {
21834
+ type: 'query',
21835
+ 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.",
21836
+ parameters: {
21837
+ type: 'params',
21838
+ required: ['space', 'repo'],
21839
+ properties: {
21840
+ space: {
21841
+ type: 'string',
21842
+ format: 'space-ref',
21843
+ },
21844
+ repo: {
21845
+ type: 'string',
21846
+ format: 'did',
21847
+ },
21848
+ },
21849
+ },
21850
+ output: {
21851
+ encoding: 'application/vnd.dasl.star',
21852
+ },
21853
+ errors: [
21854
+ {
21855
+ name: 'InvalidSpaceMac',
21856
+ description: 'The MAC requested in the Accept-Signature header is missing or invalid.',
21857
+ },
21858
+ {
21859
+ name: 'SpaceNotFound',
21860
+ },
21861
+ {
21862
+ name: 'RepoNotFound',
21863
+ },
21864
+ {
21865
+ name: 'RepoTakendown',
21866
+ },
21867
+ {
21868
+ name: 'RepoSuspended',
21869
+ },
21870
+ {
21871
+ name: 'RepoDeactivated',
21872
+ },
21873
+ ],
21874
+ },
21875
+ },
21876
+ },
21877
+ ComAtprotoSpaceGetSpace: {
21878
+ lexicon: 1,
21879
+ id: 'com.atproto.space.getSpace',
21880
+ defs: {
21881
+ main: {
21882
+ type: 'query',
21883
+ description: 'Get a space and its policy. Requires auth as the space authority, implemented by PDS.',
21884
+ parameters: {
21885
+ type: 'params',
21886
+ required: ['space'],
21887
+ properties: {
21888
+ space: {
21889
+ type: 'string',
21890
+ format: 'space-ref',
21891
+ },
21892
+ },
21893
+ },
21894
+ output: {
21895
+ encoding: 'application/json',
21896
+ schema: {
21897
+ type: 'object',
21898
+ required: ['space', 'policy'],
21899
+ properties: {
21900
+ space: {
21901
+ type: 'string',
21902
+ format: 'space-ref',
21903
+ },
21904
+ policy: {
21905
+ type: 'union',
21906
+ 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.',
21907
+ refs: [
21908
+ 'lex:com.atproto.personalspace.policy',
21909
+ 'lex:com.atproto.memberspace.policy',
21910
+ 'lex:com.atproto.managedspace.policy',
21911
+ ],
21912
+ },
21913
+ },
21914
+ },
21915
+ },
21916
+ errors: [
21917
+ {
21918
+ name: 'SpaceNotFound',
21919
+ },
21920
+ {
21921
+ name: 'NotAuthorized',
21922
+ },
21923
+ ],
21924
+ },
21925
+ },
21926
+ },
21927
+ ComAtprotoSpaceImportRepo: {
21928
+ lexicon: 1,
21929
+ id: 'com.atproto.space.importRepo',
21930
+ defs: {
21931
+ main: {
21932
+ type: 'procedure',
21933
+ 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.",
21934
+ input: {
21935
+ encoding: 'application/vnd.dasl.star',
21936
+ },
21937
+ errors: [
21938
+ {
21939
+ name: 'SpaceNotFound',
21940
+ description: "The account is the space's authority, and the space has not been imported yet.",
21941
+ },
21942
+ {
21943
+ name: 'InvalidRepoFile',
21944
+ description: 'The STAR file is malformed or fails verification.',
21945
+ },
21946
+ {
21947
+ name: 'RepoMismatch',
21948
+ description: 'The repo in the STAR file does not belong to the authenticated account.',
21949
+ },
21950
+ ],
21951
+ },
21952
+ },
21953
+ },
21954
+ ComAtprotoSpaceImportSpaceMeta: {
21955
+ lexicon: 1,
21956
+ id: 'com.atproto.space.importSpaceMeta',
21957
+ defs: {
21958
+ main: {
21959
+ type: 'procedure',
21960
+ 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.",
21961
+ input: {
21962
+ encoding: 'application/vnd.dasl.star',
21963
+ },
21964
+ errors: [
21965
+ {
21966
+ name: 'NotAuthorized',
21967
+ },
21968
+ {
21969
+ name: 'UnsupportedPolicy',
21970
+ },
21971
+ {
21972
+ name: 'InvalidSpaceMeta',
21973
+ description: 'The STAR file is malformed or fails verification.',
21974
+ },
21975
+ ],
21976
+ },
21977
+ },
21978
+ },
21979
+ ComAtprotoSpaceListBlobs: {
21980
+ lexicon: 1,
21981
+ id: 'com.atproto.space.listBlobs',
21982
+ defs: {
21983
+ main: {
21984
+ type: 'query',
21985
+ 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.",
21986
+ parameters: {
21987
+ type: 'params',
21988
+ required: ['space', 'repo'],
21989
+ properties: {
21990
+ space: {
21991
+ type: 'string',
21992
+ format: 'space-ref',
21993
+ },
21994
+ repo: {
21995
+ type: 'string',
21996
+ format: 'did',
21997
+ },
21998
+ limit: {
21999
+ type: 'integer',
22000
+ minimum: 1,
22001
+ maximum: 1000,
22002
+ default: 500,
22003
+ },
22004
+ cursor: {
22005
+ type: 'string',
22006
+ },
22007
+ },
22008
+ },
22009
+ output: {
22010
+ encoding: 'application/json',
22011
+ schema: {
22012
+ type: 'object',
22013
+ required: ['cids'],
22014
+ properties: {
22015
+ cursor: {
22016
+ type: 'string',
22017
+ },
22018
+ cids: {
22019
+ type: 'array',
22020
+ items: {
22021
+ type: 'string',
22022
+ format: 'cid',
22023
+ },
22024
+ },
22025
+ },
22026
+ },
22027
+ },
22028
+ errors: [
22029
+ {
22030
+ name: 'SpaceNotFound',
22031
+ },
22032
+ {
22033
+ name: 'RepoNotFound',
22034
+ },
22035
+ {
22036
+ name: 'RepoTakendown',
22037
+ },
22038
+ {
22039
+ name: 'RepoSuspended',
22040
+ },
22041
+ {
22042
+ name: 'RepoDeactivated',
22043
+ },
22044
+ ],
22045
+ },
22046
+ },
22047
+ },
22048
+ ComAtprotoSpaceListRecords: {
22049
+ lexicon: 1,
22050
+ id: 'com.atproto.space.listRecords',
22051
+ defs: {
22052
+ main: {
22053
+ type: 'query',
22054
+ 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.",
22055
+ parameters: {
22056
+ type: 'params',
22057
+ required: ['space', 'repo'],
22058
+ properties: {
22059
+ space: {
22060
+ type: 'string',
22061
+ format: 'space-ref',
22062
+ },
22063
+ repo: {
22064
+ type: 'string',
22065
+ format: 'did',
22066
+ },
22067
+ collection: {
22068
+ type: 'string',
22069
+ format: 'nsid',
22070
+ description: 'If omitted, lists records across all collections.',
22071
+ },
22072
+ limit: {
22073
+ type: 'integer',
22074
+ minimum: 1,
22075
+ maximum: 1000,
22076
+ default: 50,
22077
+ },
22078
+ cursor: {
22079
+ type: 'string',
22080
+ },
22081
+ excludeValues: {
22082
+ type: 'boolean',
22083
+ default: false,
22084
+ },
22085
+ },
22086
+ },
22087
+ output: {
22088
+ encoding: 'application/json',
22089
+ schema: {
22090
+ type: 'object',
22091
+ required: ['records'],
22092
+ properties: {
22093
+ cursor: {
22094
+ type: 'string',
22095
+ },
22096
+ records: {
22097
+ type: 'array',
22098
+ items: {
22099
+ type: 'ref',
22100
+ ref: 'lex:com.atproto.space.listRecords#record',
22101
+ },
22102
+ },
22103
+ },
22104
+ },
22105
+ },
22106
+ errors: [
22107
+ {
22108
+ name: 'SpaceNotFound',
22109
+ },
22110
+ {
22111
+ name: 'RepoNotFound',
22112
+ },
22113
+ {
22114
+ name: 'RepoTakendown',
22115
+ },
22116
+ {
22117
+ name: 'RepoSuspended',
22118
+ },
22119
+ {
22120
+ name: 'RepoDeactivated',
22121
+ },
22122
+ {
22123
+ name: 'InvalidCursor',
22124
+ },
22125
+ ],
22126
+ },
22127
+ record: {
22128
+ type: 'object',
22129
+ required: ['collection', 'rkey', 'cid'],
22130
+ properties: {
22131
+ collection: {
22132
+ type: 'string',
22133
+ format: 'nsid',
22134
+ },
22135
+ rkey: {
22136
+ type: 'string',
22137
+ format: 'record-key',
22138
+ },
22139
+ cid: {
22140
+ type: 'string',
22141
+ format: 'cid',
22142
+ },
22143
+ value: {
22144
+ type: 'unknown',
22145
+ },
22146
+ },
22147
+ },
22148
+ },
22149
+ },
22150
+ ComAtprotoSpaceListRepoOps: {
22151
+ lexicon: 1,
22152
+ id: 'com.atproto.space.listRepoOps',
22153
+ defs: {
22154
+ main: {
22155
+ type: 'query',
22156
+ 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.",
22157
+ parameters: {
22158
+ type: 'params',
22159
+ required: ['space', 'repo'],
22160
+ properties: {
22161
+ space: {
22162
+ type: 'string',
22163
+ format: 'space-ref',
22164
+ },
22165
+ repo: {
22166
+ type: 'string',
22167
+ format: 'did',
22168
+ },
22169
+ since: {
22170
+ type: 'string',
22171
+ format: 'tid',
22172
+ },
22173
+ limit: {
22174
+ type: 'integer',
22175
+ minimum: 1,
22176
+ maximum: 1000,
22177
+ default: 100,
22178
+ },
22179
+ cursor: {
22180
+ type: 'string',
22181
+ },
22182
+ excludeValues: {
22183
+ type: 'boolean',
22184
+ default: false,
22185
+ },
22186
+ },
22187
+ },
22188
+ output: {
22189
+ encoding: 'application/json',
22190
+ schema: {
22191
+ type: 'object',
22192
+ required: ['ops', 'commit'],
22193
+ properties: {
22194
+ ops: {
22195
+ type: 'array',
22196
+ items: {
22197
+ type: 'ref',
22198
+ ref: 'lex:com.atproto.space.listRepoOps#opEntry',
22199
+ },
22200
+ },
22201
+ commit: {
22202
+ type: 'ref',
22203
+ ref: 'lex:com.atproto.space.defs#commit',
22204
+ 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.",
22205
+ },
22206
+ cursor: {
22207
+ type: 'string',
22208
+ },
22209
+ },
22210
+ },
22211
+ },
22212
+ errors: [
22213
+ {
22214
+ name: 'InvalidSpaceMac',
22215
+ description: 'The MAC requested in the Accept-Signature header is missing or invalid.',
22216
+ },
22217
+ {
22218
+ name: 'SpaceNotFound',
22219
+ },
22220
+ {
22221
+ name: 'RepoNotFound',
22222
+ },
22223
+ {
22224
+ name: 'RepoTakendown',
22225
+ },
22226
+ {
22227
+ name: 'RepoSuspended',
22228
+ },
22229
+ {
22230
+ name: 'RepoDeactivated',
22231
+ },
22232
+ {
22233
+ name: 'InvalidCursor',
22234
+ },
22235
+ ],
22236
+ },
22237
+ opEntry: {
22238
+ type: 'object',
22239
+ description: 'Operations that share a rev were applied in the same commit.',
22240
+ required: ['rev', 'collection', 'rkey', 'cid', 'prev'],
22241
+ nullable: ['cid', 'prev'],
22242
+ properties: {
22243
+ rev: {
22244
+ type: 'string',
22245
+ format: 'tid',
22246
+ },
22247
+ collection: {
22248
+ type: 'string',
22249
+ format: 'nsid',
22250
+ },
22251
+ rkey: {
22252
+ type: 'string',
22253
+ format: 'record-key',
22254
+ },
22255
+ cid: {
22256
+ type: 'string',
22257
+ format: 'cid',
22258
+ description: 'CID of the record after the operation. Null for deletes.',
22259
+ },
22260
+ prev: {
22261
+ type: 'string',
22262
+ format: 'cid',
22263
+ description: 'CID of the record before the operation. Null for creates.',
22264
+ },
22265
+ value: {
22266
+ type: 'unknown',
22267
+ description: 'Omitted for deletes, if excludeValues is set, or if the record has since changed.',
22268
+ },
22269
+ },
22270
+ },
22271
+ },
22272
+ },
22273
+ ComAtprotoSpaceListSpaces: {
22274
+ lexicon: 1,
22275
+ id: 'com.atproto.space.listSpaces',
22276
+ defs: {
22277
+ main: {
22278
+ type: 'query',
22279
+ description: 'List spaces that the authenticated account has written to or is the authority for. Requires auth, implemented by PDS.',
22280
+ parameters: {
22281
+ type: 'params',
22282
+ properties: {
22283
+ spaceDid: {
22284
+ type: 'string',
22285
+ format: 'did',
22286
+ description: 'Filter to spaces with this DID as their authority.',
22287
+ },
22288
+ spaceType: {
22289
+ type: 'string',
22290
+ format: 'nsid',
22291
+ },
22292
+ limit: {
22293
+ type: 'integer',
22294
+ minimum: 1,
22295
+ maximum: 100,
22296
+ default: 50,
22297
+ },
22298
+ cursor: {
22299
+ type: 'string',
22300
+ },
22301
+ },
22302
+ },
22303
+ output: {
22304
+ encoding: 'application/json',
22305
+ schema: {
22306
+ type: 'object',
22307
+ required: ['spaces'],
22308
+ properties: {
22309
+ cursor: {
22310
+ type: 'string',
22311
+ },
22312
+ spaces: {
22313
+ type: 'array',
22314
+ items: {
22315
+ type: 'ref',
22316
+ ref: 'lex:com.atproto.space.listSpaces#spaceView',
22317
+ },
22318
+ },
22319
+ },
22320
+ },
22321
+ },
22322
+ errors: [
22323
+ {
22324
+ name: 'InvalidCursor',
22325
+ },
22326
+ ],
22327
+ },
22328
+ spaceView: {
22329
+ type: 'object',
22330
+ required: ['space'],
22331
+ properties: {
22332
+ space: {
22333
+ type: 'string',
22334
+ format: 'space-ref',
22335
+ },
22336
+ repoRev: {
22337
+ type: 'string',
22338
+ format: 'tid',
22339
+ description: "The current revision of the account's repo in the space, if it has one.",
22340
+ },
22341
+ data: {
22342
+ type: 'bytes',
22343
+ description: "The current commit data of the account's repo in the space, if it has one.",
22344
+ },
22345
+ spaceRev: {
22346
+ type: 'string',
22347
+ format: 'tid',
22348
+ description: "The current revision of the space. Only included if the account is the space's authority.",
22349
+ },
22350
+ },
22351
+ },
22352
+ },
22353
+ },
22354
+ ComAtprotoSpaceListWriters: {
22355
+ lexicon: 1,
22356
+ id: 'com.atproto.space.listWriters',
22357
+ defs: {
22358
+ main: {
22359
+ type: 'query',
22360
+ 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.",
22361
+ parameters: {
22362
+ type: 'params',
22363
+ required: ['space'],
22364
+ properties: {
22365
+ space: {
22366
+ type: 'string',
22367
+ format: 'space-ref',
22368
+ },
22369
+ limit: {
22370
+ type: 'integer',
22371
+ minimum: 1,
22372
+ maximum: 1000,
22373
+ default: 100,
22374
+ },
22375
+ cursor: {
22376
+ type: 'string',
22377
+ 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.',
22378
+ },
22379
+ },
22380
+ },
22381
+ output: {
22382
+ encoding: 'application/json',
22383
+ schema: {
22384
+ type: 'object',
22385
+ required: ['repos'],
22386
+ properties: {
22387
+ repos: {
22388
+ type: 'array',
22389
+ items: {
22390
+ type: 'union',
22391
+ refs: [
22392
+ 'lex:com.atproto.space.defs#repoWrite',
22393
+ 'lex:com.atproto.space.defs#repoRemoved',
22394
+ ],
22395
+ },
22396
+ description: 'The latest update to each repo, ordered by spaceRev, ascending. prevSpaceRev is not set.',
22397
+ },
22398
+ cursor: {
22399
+ type: 'string',
22400
+ },
22401
+ },
22402
+ },
22403
+ },
22404
+ errors: [
22405
+ {
22406
+ name: 'SpaceNotFound',
22407
+ },
22408
+ {
22409
+ name: 'RepoTakendown',
22410
+ description: 'The space authority has been taken down.',
22411
+ },
22412
+ {
22413
+ name: 'RepoDeactivated',
22414
+ description: 'The space authority has been deactivated.',
22415
+ },
22416
+ ],
22417
+ },
22418
+ },
22419
+ },
22420
+ ComAtprotoSpaceNotifyCredentialsRevoked: {
22421
+ lexicon: 1,
22422
+ id: 'com.atproto.space.notifyCredentialsRevoked',
22423
+ defs: {
22424
+ main: {
22425
+ type: 'procedure',
22426
+ description: 'Notify a repo host that space credentials have been revoked. Sent by the space host. Requires service auth, implemented by PDS.',
22427
+ input: {
22428
+ encoding: 'application/json',
22429
+ schema: {
22430
+ type: 'object',
22431
+ required: ['space', 'credentials'],
22432
+ properties: {
22433
+ space: {
22434
+ type: 'string',
22435
+ format: 'space-ref',
22436
+ },
22437
+ credentials: {
22438
+ type: 'array',
22439
+ minLength: 1,
22440
+ maxLength: 100,
22441
+ description: 'The IDs (jti) of the revoked credentials.',
22442
+ items: {
22443
+ type: 'string',
22444
+ minLength: 1,
22445
+ },
22446
+ },
22447
+ },
22448
+ },
22449
+ },
22450
+ },
22451
+ },
22452
+ },
22453
+ ComAtprotoSpaceNotifyRepoUpdate: {
22454
+ lexicon: 1,
22455
+ id: 'com.atproto.space.notifyRepoUpdate',
22456
+ defs: {
22457
+ main: {
22458
+ type: 'procedure',
22459
+ description: 'Notify the space host that a space repo has been updated. Sent by repo hosts, with service auth.',
22460
+ input: {
22461
+ encoding: 'application/json',
22462
+ schema: {
22463
+ type: 'object',
22464
+ required: ['space', 'repo', 'repoRev', 'data'],
22465
+ properties: {
22466
+ space: {
22467
+ type: 'string',
22468
+ format: 'space-ref',
22469
+ },
22470
+ repo: {
22471
+ type: 'string',
22472
+ format: 'did',
22473
+ },
22474
+ repoRev: {
22475
+ type: 'string',
22476
+ format: 'tid',
22477
+ },
22478
+ data: {
22479
+ type: 'bytes',
22480
+ description: "SHA-256 digest of the repo's LtHash state.",
22481
+ },
22482
+ },
22483
+ },
22484
+ },
22485
+ errors: [
22486
+ {
22487
+ name: 'SpaceNotFound',
22488
+ },
22489
+ {
22490
+ name: 'FutureRev',
22491
+ description: 'The repo revision is too far in the future.',
22492
+ },
22493
+ ],
22494
+ },
22495
+ },
22496
+ },
22497
+ ComAtprotoSpaceNotifySpaceUpdate: {
22498
+ lexicon: 1,
22499
+ id: 'com.atproto.space.notifySpaceUpdate',
22500
+ defs: {
22501
+ main: {
22502
+ type: 'procedure',
22503
+ description: 'Notify a syncing service of an update to a space. Sent by the space host to the notification endpoint registered through authorizeSpaceSync.',
22504
+ input: {
22505
+ encoding: 'application/json',
22506
+ schema: {
22507
+ type: 'object',
22508
+ required: ['space', 'token', 'update'],
22509
+ properties: {
22510
+ space: {
22511
+ type: 'string',
22512
+ format: 'space-ref',
22513
+ },
22514
+ token: {
22515
+ type: 'string',
22516
+ maxLength: 512,
22517
+ description: 'The token the endpoint was registered with.',
22518
+ },
22519
+ update: {
22520
+ type: 'union',
22521
+ refs: [
22522
+ 'lex:com.atproto.space.defs#repoWrite',
22523
+ 'lex:com.atproto.space.defs#repoRemoved',
22524
+ 'lex:com.atproto.space.notifySpaceUpdate#spaceDeleted',
22525
+ 'lex:com.atproto.space.notifySpaceUpdate#registrationExpired',
22526
+ ],
22527
+ },
22528
+ },
22529
+ },
22530
+ },
22531
+ },
22532
+ spaceDeleted: {
22533
+ type: 'object',
22534
+ description: 'The space has been deleted. Confirm with authorizeSpaceSync before dropping its data.',
22535
+ properties: {},
22536
+ },
22537
+ registrationExpired: {
22538
+ type: 'object',
22539
+ description: "The endpoint's registration has expired. Sent in place of the first update after expiry. Call authorizeSpaceSync to keep receiving notifications.",
22540
+ required: ['spaceRev'],
22541
+ properties: {
22542
+ spaceRev: {
22543
+ type: 'string',
22544
+ format: 'tid',
22545
+ },
22546
+ },
22547
+ },
22548
+ },
22549
+ },
22550
+ ComAtprotoSpacePolicy: {
22551
+ lexicon: 1,
22552
+ id: 'com.atproto.space.policy',
22553
+ defs: {
22554
+ main: {
22555
+ type: 'record',
22556
+ description: "A published copy of a space's policy. Only authoritative in the space authority's repo.",
22557
+ key: 'literal:self',
22558
+ record: {
22559
+ type: 'object',
22560
+ required: ['policy'],
22561
+ properties: {
22562
+ policy: {
22563
+ type: 'union',
22564
+ 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.',
22565
+ refs: [
22566
+ 'lex:com.atproto.personalspace.policy',
22567
+ 'lex:com.atproto.memberspace.policy',
22568
+ 'lex:com.atproto.managedspace.policy',
22569
+ ],
22570
+ },
22571
+ },
22572
+ },
22573
+ },
22574
+ },
22575
+ },
22576
+ ComAtprotoSpacePutRecord: {
22577
+ lexicon: 1,
22578
+ id: 'com.atproto.space.putRecord',
22579
+ defs: {
22580
+ main: {
22581
+ type: 'procedure',
22582
+ description: 'Write a record in a space repo, creating or updating it as needed. Requires auth, implemented by PDS.',
22583
+ input: {
22584
+ encoding: 'application/json',
22585
+ schema: {
22586
+ type: 'object',
22587
+ required: ['space', 'repo', 'collection', 'rkey', 'record'],
22588
+ properties: {
22589
+ space: {
22590
+ type: 'string',
22591
+ format: 'space-ref',
22592
+ },
22593
+ repo: {
22594
+ type: 'string',
22595
+ format: 'did',
22596
+ },
22597
+ collection: {
22598
+ type: 'string',
22599
+ format: 'nsid',
22600
+ },
22601
+ rkey: {
22602
+ type: 'string',
22603
+ format: 'record-key',
22604
+ },
22605
+ validate: {
22606
+ type: 'boolean',
22607
+ description: "Can be set to 'false' to skip Lexicon schema validation of record data, 'true' to require it, or leave unset to validate only for known Lexicons.",
22608
+ },
22609
+ record: {
22610
+ type: 'unknown',
22611
+ },
22612
+ },
22613
+ },
22614
+ },
22615
+ output: {
22616
+ encoding: 'application/json',
22617
+ schema: {
22618
+ type: 'object',
22619
+ required: ['uri', 'cid'],
22620
+ properties: {
22621
+ uri: {
22622
+ type: 'string',
22623
+ format: 'at-uri',
22624
+ },
22625
+ cid: {
22626
+ type: 'string',
22627
+ format: 'cid',
22628
+ },
22629
+ validationStatus: {
22630
+ type: 'string',
22631
+ knownValues: ['valid', 'unknown'],
22632
+ },
22633
+ },
22634
+ },
22635
+ },
22636
+ errors: [
22637
+ {
22638
+ name: 'SpaceNotFound',
22639
+ },
22640
+ ],
22641
+ },
22642
+ },
22643
+ },
22644
+ ComAtprotoSpaceRemoveWriter: {
22645
+ lexicon: 1,
22646
+ id: 'com.atproto.space.removeWriter',
22647
+ defs: {
22648
+ main: {
22649
+ type: 'procedure',
22650
+ description: "Remove an account from a space's writer set, as returned by listWriters. The removal is sent to registered syncers. The account is added back if it makes another authorized write to the space. Does nothing if the account is not in the writer set. Requires auth as the space authority, implemented by PDS.",
22651
+ input: {
22652
+ encoding: 'application/json',
22653
+ schema: {
22654
+ type: 'object',
22655
+ required: ['space', 'repo'],
22656
+ properties: {
22657
+ space: {
22658
+ type: 'string',
22659
+ format: 'space-ref',
22660
+ },
22661
+ repo: {
22662
+ type: 'string',
22663
+ format: 'did',
22664
+ },
22665
+ },
22666
+ },
22667
+ },
22668
+ errors: [
22669
+ {
22670
+ name: 'SpaceNotFound',
22671
+ },
22672
+ {
22673
+ name: 'NotAuthorized',
22674
+ },
22675
+ ],
22676
+ },
22677
+ },
22678
+ },
22679
+ ComAtprotoSpaceUpdateSpace: {
22680
+ lexicon: 1,
22681
+ id: 'com.atproto.space.updateSpace',
22682
+ defs: {
22683
+ main: {
22684
+ type: 'procedure',
22685
+ description: 'Replace the policy of a space. Changing to a different policy type discards state held by the previous policy, such as a member list. Requires auth as the space authority, implemented by PDS.',
22686
+ input: {
22687
+ encoding: 'application/json',
22688
+ schema: {
22689
+ type: 'object',
22690
+ required: ['space', 'policy'],
22691
+ properties: {
22692
+ space: {
22693
+ type: 'string',
22694
+ format: 'space-ref',
22695
+ },
22696
+ policy: {
22697
+ type: 'union',
22698
+ 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.',
22699
+ refs: [
22700
+ 'lex:com.atproto.personalspace.policy',
22701
+ 'lex:com.atproto.memberspace.policy',
22702
+ 'lex:com.atproto.managedspace.policy',
22703
+ ],
22704
+ },
22705
+ },
22706
+ },
22707
+ },
22708
+ errors: [
22709
+ {
22710
+ name: 'SpaceNotFound',
22711
+ },
22712
+ {
22713
+ name: 'NotAuthorized',
22714
+ },
22715
+ {
22716
+ name: 'UnsupportedPolicy',
22717
+ },
22718
+ ],
22719
+ },
22720
+ },
22721
+ },
20626
22722
  ComAtprotoSyncDefs: {
20627
22723
  lexicon: 1,
20628
22724
  id: 'com.atproto.sync.defs',
@@ -31186,8 +33282,17 @@ export const ids = {
31186
33282
  ComAtprotoLabelSubscribeLabels: 'com.atproto.label.subscribeLabels',
31187
33283
  ComAtprotoLexiconResolveLexicon: 'com.atproto.lexicon.resolveLexicon',
31188
33284
  ComAtprotoLexiconSchema: 'com.atproto.lexicon.schema',
33285
+ ComAtprotoManagedspaceCheckAccess: 'com.atproto.managedspace.checkAccess',
33286
+ ComAtprotoManagedspacePolicy: 'com.atproto.managedspace.policy',
33287
+ ComAtprotoMemberspaceDefs: 'com.atproto.memberspace.defs',
33288
+ ComAtprotoMemberspaceListMembers: 'com.atproto.memberspace.listMembers',
33289
+ ComAtprotoMemberspaceMember: 'com.atproto.memberspace.member',
33290
+ ComAtprotoMemberspacePolicy: 'com.atproto.memberspace.policy',
33291
+ ComAtprotoMemberspacePutMembers: 'com.atproto.memberspace.putMembers',
33292
+ ComAtprotoMemberspaceRemoveMembers: 'com.atproto.memberspace.removeMembers',
31189
33293
  ComAtprotoModerationCreateReport: 'com.atproto.moderation.createReport',
31190
33294
  ComAtprotoModerationDefs: 'com.atproto.moderation.defs',
33295
+ ComAtprotoPersonalspacePolicy: 'com.atproto.personalspace.policy',
31191
33296
  ComAtprotoRepoApplyWrites: 'com.atproto.repo.applyWrites',
31192
33297
  ComAtprotoRepoCreateRecord: 'com.atproto.repo.createRecord',
31193
33298
  ComAtprotoRepoDefs: 'com.atproto.repo.defs',
@@ -31227,6 +33332,36 @@ export const ids = {
31227
33332
  ComAtprotoServerResetPassword: 'com.atproto.server.resetPassword',
31228
33333
  ComAtprotoServerRevokeAppPassword: 'com.atproto.server.revokeAppPassword',
31229
33334
  ComAtprotoServerUpdateEmail: 'com.atproto.server.updateEmail',
33335
+ ComAtprotoSpaceApplyWrites: 'com.atproto.space.applyWrites',
33336
+ ComAtprotoSpaceAuthorizeSpaceSync: 'com.atproto.space.authorizeSpaceSync',
33337
+ ComAtprotoSpaceClearRecords: 'com.atproto.space.clearRecords',
33338
+ ComAtprotoSpaceConfirmRegistration: 'com.atproto.space.confirmRegistration',
33339
+ ComAtprotoSpaceCreateRecord: 'com.atproto.space.createRecord',
33340
+ ComAtprotoSpaceCreateSpace: 'com.atproto.space.createSpace',
33341
+ ComAtprotoSpaceDefs: 'com.atproto.space.defs',
33342
+ ComAtprotoSpaceDeleteRecord: 'com.atproto.space.deleteRecord',
33343
+ ComAtprotoSpaceDeleteSpace: 'com.atproto.space.deleteSpace',
33344
+ ComAtprotoSpaceExportSpaceMeta: 'com.atproto.space.exportSpaceMeta',
33345
+ ComAtprotoSpaceGetBlob: 'com.atproto.space.getBlob',
33346
+ ComAtprotoSpaceGetDelegationToken: 'com.atproto.space.getDelegationToken',
33347
+ ComAtprotoSpaceGetLatestCommit: 'com.atproto.space.getLatestCommit',
33348
+ ComAtprotoSpaceGetRecord: 'com.atproto.space.getRecord',
33349
+ ComAtprotoSpaceGetRepo: 'com.atproto.space.getRepo',
33350
+ ComAtprotoSpaceGetSpace: 'com.atproto.space.getSpace',
33351
+ ComAtprotoSpaceImportRepo: 'com.atproto.space.importRepo',
33352
+ ComAtprotoSpaceImportSpaceMeta: 'com.atproto.space.importSpaceMeta',
33353
+ ComAtprotoSpaceListBlobs: 'com.atproto.space.listBlobs',
33354
+ ComAtprotoSpaceListRecords: 'com.atproto.space.listRecords',
33355
+ ComAtprotoSpaceListRepoOps: 'com.atproto.space.listRepoOps',
33356
+ ComAtprotoSpaceListSpaces: 'com.atproto.space.listSpaces',
33357
+ ComAtprotoSpaceListWriters: 'com.atproto.space.listWriters',
33358
+ ComAtprotoSpaceNotifyCredentialsRevoked: 'com.atproto.space.notifyCredentialsRevoked',
33359
+ ComAtprotoSpaceNotifyRepoUpdate: 'com.atproto.space.notifyRepoUpdate',
33360
+ ComAtprotoSpaceNotifySpaceUpdate: 'com.atproto.space.notifySpaceUpdate',
33361
+ ComAtprotoSpacePolicy: 'com.atproto.space.policy',
33362
+ ComAtprotoSpacePutRecord: 'com.atproto.space.putRecord',
33363
+ ComAtprotoSpaceRemoveWriter: 'com.atproto.space.removeWriter',
33364
+ ComAtprotoSpaceUpdateSpace: 'com.atproto.space.updateSpace',
31230
33365
  ComAtprotoSyncDefs: 'com.atproto.sync.defs',
31231
33366
  ComAtprotoSyncGetBlob: 'com.atproto.sync.getBlob',
31232
33367
  ComAtprotoSyncGetBlocks: 'com.atproto.sync.getBlocks',