@atproto/api 0.6.24 → 0.7.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.
- package/CHANGELOG.md +6 -0
- package/definitions/labels.json +6 -0
- package/definitions/locale/en/labels.json +14 -0
- package/definitions/moderation-behaviors.d.ts +1 -0
- package/definitions/post-moderation-behaviors.json +118 -0
- package/definitions/profile-moderation-behaviors.json +48 -0
- package/dist/client/index.d.ts +12 -0
- package/dist/client/lexicons.d.ts +134 -0
- package/dist/client/types/com/atproto/admin/deleteAccount.d.ts +17 -0
- package/dist/client/types/com/atproto/temp/importRepo.d.ts +16 -0
- package/dist/client/types/com/atproto/temp/pushBlob.d.ts +15 -0
- package/dist/client/types/com/atproto/temp/transferAccount.d.ts +48 -0
- package/dist/index.js +635 -325
- package/dist/index.js.map +3 -3
- package/dist/moderation/types.d.ts +1 -1
- package/docs/labels.md +16 -0
- package/docs/moderation-behaviors/posts.md +159 -92
- package/docs/moderation-behaviors/profiles.md +68 -0
- package/package.json +2 -2
- package/scripts/docs/labels.mjs +27 -27
- package/scripts/docs/post-moderation-behaviors.mjs +43 -48
- package/src/client/index.ts +52 -0
- package/src/client/lexicons.ts +156 -0
- package/src/client/types/com/atproto/admin/deleteAccount.ts +32 -0
- package/src/client/types/com/atproto/temp/importRepo.ts +33 -0
- package/src/client/types/com/atproto/temp/pushBlob.ts +32 -0
- package/src/client/types/com/atproto/temp/transferAccount.ts +92 -0
- package/src/moderation/accumulator.ts +5 -0
- package/src/moderation/const/label-groups.ts +6 -1
- package/src/moderation/const/labels.ts +31 -0
- package/src/moderation/types.ts +1 -1
- package/tests/util/moderation-behavior.ts +4 -1
|
@@ -131,6 +131,74 @@ Key:
|
|
|
131
131
|
</td>
|
|
132
132
|
</tr>
|
|
133
133
|
|
|
134
|
+
<tr>
|
|
135
|
+
<td><strong>Imperative label ('!no-unauthenticated') on account when logged out</strong></td>
|
|
136
|
+
<td>
|
|
137
|
+
❌
|
|
138
|
+
</td>
|
|
139
|
+
<td>
|
|
140
|
+
🚫
|
|
141
|
+
|
|
142
|
+
</td>
|
|
143
|
+
<td>
|
|
144
|
+
|
|
145
|
+
</td>
|
|
146
|
+
<td>
|
|
147
|
+
🚫
|
|
148
|
+
|
|
149
|
+
</td>
|
|
150
|
+
</tr>
|
|
151
|
+
|
|
152
|
+
<tr>
|
|
153
|
+
<td><strong>Imperative label ('!no-unauthenticated') on profile when logged out</strong></td>
|
|
154
|
+
<td>
|
|
155
|
+
|
|
156
|
+
</td>
|
|
157
|
+
<td>
|
|
158
|
+
|
|
159
|
+
</td>
|
|
160
|
+
<td>
|
|
161
|
+
🚫
|
|
162
|
+
|
|
163
|
+
</td>
|
|
164
|
+
<td>
|
|
165
|
+
🚫
|
|
166
|
+
|
|
167
|
+
</td>
|
|
168
|
+
</tr>
|
|
169
|
+
|
|
170
|
+
<tr>
|
|
171
|
+
<td><strong>Imperative label ('!no-unauthenticated') on account when logged in</strong></td>
|
|
172
|
+
<td>
|
|
173
|
+
|
|
174
|
+
</td>
|
|
175
|
+
<td>
|
|
176
|
+
|
|
177
|
+
</td>
|
|
178
|
+
<td>
|
|
179
|
+
|
|
180
|
+
</td>
|
|
181
|
+
<td>
|
|
182
|
+
|
|
183
|
+
</td>
|
|
184
|
+
</tr>
|
|
185
|
+
|
|
186
|
+
<tr>
|
|
187
|
+
<td><strong>Imperative label ('!no-unauthenticated') on profile when logged in</strong></td>
|
|
188
|
+
<td>
|
|
189
|
+
|
|
190
|
+
</td>
|
|
191
|
+
<td>
|
|
192
|
+
|
|
193
|
+
</td>
|
|
194
|
+
<td>
|
|
195
|
+
|
|
196
|
+
</td>
|
|
197
|
+
<td>
|
|
198
|
+
|
|
199
|
+
</td>
|
|
200
|
+
</tr>
|
|
201
|
+
|
|
134
202
|
<tr><th>Scenario</th><th>Filter</th><th>Account</th><th>Profile</td><th>Avatar</th></tr>
|
|
135
203
|
<tr>
|
|
136
204
|
<td><strong>Blur label ('intolerant') on account (hide)</strong></td>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atproto/api",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.7.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "Client library for atproto and Bluesky",
|
|
6
6
|
"keywords": [
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
"devDependencies": {
|
|
29
29
|
"common-tags": "^1.8.2",
|
|
30
30
|
"@atproto/lex-cli": "^0.2.5",
|
|
31
|
-
"@atproto/dev-env": "^0.2.
|
|
31
|
+
"@atproto/dev-env": "^0.2.17"
|
|
32
32
|
},
|
|
33
33
|
"scripts": {
|
|
34
34
|
"codegen": "pnpm docgen && node ./scripts/generate-code.mjs && lex gen-api ./src/client ../../lexicons/com/atproto/*/* ../../lexicons/app/bsky/*/*",
|
package/scripts/docs/labels.mjs
CHANGED
|
@@ -36,47 +36,47 @@ writeFileSync(join(__dirname, '..', '..', 'docs', 'labels.md'), doc(), 'utf8')
|
|
|
36
36
|
|
|
37
37
|
function doc() {
|
|
38
38
|
return stripIndent`
|
|
39
|
-
|
|
39
|
+
<!-- this doc is generated by ./scripts/docs/labels.mjs -->
|
|
40
40
|
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
This document is a reference for the labels used in the SDK.
|
|
41
|
+
# Labels
|
|
44
42
|
|
|
45
|
-
|
|
43
|
+
This document is a reference for the labels used in the SDK.
|
|
46
44
|
|
|
47
|
-
|
|
45
|
+
**⚠️ Note**: These labels are still in development and may change over time. Not all are currently in use.
|
|
48
46
|
|
|
49
|
-
|
|
47
|
+
## Key
|
|
50
48
|
|
|
51
|
-
|
|
49
|
+
### Label Preferences
|
|
52
50
|
|
|
53
|
-
|
|
54
|
-
- <code>warn</code> Provide some form of warning on the content (see "On Warn" behavior).
|
|
55
|
-
- <code>hide</code> Remove the content from feeds and apply the warning when directly viewed.
|
|
51
|
+
The possible client interpretations for a label.
|
|
56
52
|
|
|
57
|
-
|
|
53
|
+
- <code>ignore</code> Do nothing with the label.
|
|
54
|
+
- <code>warn</code> Provide some form of warning on the content (see "On Warn" behavior).
|
|
55
|
+
- <code>hide</code> Remove the content from feeds and apply the warning when directly viewed.
|
|
58
56
|
|
|
59
|
-
|
|
57
|
+
Each label specifies which preferences it can support. If a label is not configurable, it must have only own supported preference.
|
|
60
58
|
|
|
61
|
-
|
|
59
|
+
### Configurable?
|
|
62
60
|
|
|
63
|
-
|
|
61
|
+
Non-configurable labels cannot have their preference changed by the user.
|
|
64
62
|
|
|
65
|
-
|
|
63
|
+
### Flags
|
|
66
64
|
|
|
67
|
-
|
|
68
|
-
- <code>adult</code> The user must have adult content enabled to configure the label. If adult content is not enabled, the label must adopt the strictest preference.
|
|
65
|
+
Additional behaviors which a label can adopt.
|
|
69
66
|
|
|
70
|
-
|
|
67
|
+
- <code>no-override</code> The user cannot click through any covering of content created by the label.
|
|
68
|
+
- <code>adult</code> The user must have adult content enabled to configure the label. If adult content is not enabled, the label must adopt the strictest preference.
|
|
71
69
|
|
|
72
|
-
|
|
70
|
+
### On Warn
|
|
73
71
|
|
|
74
|
-
|
|
75
|
-
- <code>blur-media</code> Hide only the media within the content (ie images) behind an interstitial.
|
|
76
|
-
- <code>alert</code> Display a descriptive warning but do not hide the content.
|
|
77
|
-
- <code>null</code> Do nothing.
|
|
72
|
+
The kind of UI behavior used when a warning must be applied.
|
|
78
73
|
|
|
79
|
-
|
|
74
|
+
- <code>blur</code> Hide all of the content behind an interstitial.
|
|
75
|
+
- <code>blur-media</code> Hide only the media within the content (ie images) behind an interstitial.
|
|
76
|
+
- <code>alert</code> Display a descriptive warning but do not hide the content.
|
|
77
|
+
- <code>null</code> Do nothing.
|
|
78
|
+
|
|
79
|
+
## Label Behaviors
|
|
80
80
|
|
|
81
81
|
<table>
|
|
82
82
|
<tr>
|
|
@@ -90,7 +90,7 @@ function doc() {
|
|
|
90
90
|
${labelsRef()}
|
|
91
91
|
</table>
|
|
92
92
|
|
|
93
|
-
|
|
93
|
+
## Label Group Descriptions
|
|
94
94
|
|
|
95
95
|
<table>
|
|
96
96
|
<tr>
|
|
@@ -100,7 +100,7 @@ function doc() {
|
|
|
100
100
|
${labelGroupsDesc()}
|
|
101
101
|
</table>
|
|
102
102
|
|
|
103
|
-
|
|
103
|
+
## Label Descriptions
|
|
104
104
|
|
|
105
105
|
<table>
|
|
106
106
|
<tr>
|
|
@@ -27,44 +27,44 @@ writeFileSync(
|
|
|
27
27
|
function posts() {
|
|
28
28
|
let lastTitle = 'NULL'
|
|
29
29
|
return stripIndents`
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
30
|
+
<!-- this doc is generated by ./scripts/docs/post-moderation-behaviors.mjs -->
|
|
31
|
+
|
|
32
|
+
# Post moderation behaviors
|
|
33
|
+
|
|
34
|
+
This document is a reference for the expected behaviors for a post in the application based on some given scenarios. The <code>moderatePost()</code> command condense down to the following yes or no decisions:
|
|
35
|
+
|
|
36
|
+
- <code>res.content.filter</code> Do not show the post in feeds.
|
|
37
|
+
- <code>res.content.blur</code> Put the post behind a warning cover.
|
|
38
|
+
- <code>res.content.noOverride</code> Do not allow the post's blur cover to be lifted.
|
|
39
|
+
- <code>res.content.alert</code> Add a warning to the post but do not cover it.
|
|
40
|
+
- <code>res.avatar.blur</code> Put the avatar behind a cover.
|
|
41
|
+
- <code>res.avatar.noOverride</code> Do not allow the avatars's blur cover to be lifted.
|
|
42
|
+
- <code>res.avatar.alert</code> Put a warning icon on the avatar.
|
|
43
|
+
- <code>res.embed.blur</code> Put the embed content (media, quote post) behind a warning cover.
|
|
44
|
+
- <code>res.embed.noOverride</code> Do not allow the embed's blur cover to be lifted.
|
|
45
|
+
- <code>res.embed.alert</code> Put a warning on the embed content (media, quote post).
|
|
46
|
+
|
|
47
|
+
Key:
|
|
48
|
+
|
|
49
|
+
- ❌ = Filter Content
|
|
50
|
+
- 🚫 = Blur (no-override)
|
|
51
|
+
- ✋ = Blur
|
|
52
|
+
- 🪧 = Alert
|
|
53
|
+
|
|
54
|
+
## Scenarios
|
|
55
|
+
|
|
56
|
+
<table>
|
|
57
|
+
${Array.from(Object.entries(postModerationBehaviorsDef.scenarios))
|
|
58
|
+
.map(([title, scenario], i) => {
|
|
59
|
+
const str = `
|
|
60
|
+
${title.indexOf(lastTitle) === -1 ? postTableHead() : ''}
|
|
61
|
+
${scenarioSection(title, scenario)}
|
|
62
|
+
`
|
|
63
|
+
lastTitle = title.slice(0, 10)
|
|
64
|
+
return str
|
|
65
|
+
})
|
|
66
|
+
.join('')}
|
|
67
|
+
</table>
|
|
68
68
|
`
|
|
69
69
|
}
|
|
70
70
|
|
|
@@ -73,8 +73,7 @@ function postTableHead() {
|
|
|
73
73
|
}
|
|
74
74
|
|
|
75
75
|
function scenarioSection(title, scenario) {
|
|
76
|
-
return stripIndents
|
|
77
|
-
<tr>
|
|
76
|
+
return stripIndents`<tr>
|
|
78
77
|
<td><strong>${title}</strong></td>
|
|
79
78
|
<td>
|
|
80
79
|
${filter(scenario.behaviors.content?.filter)}
|
|
@@ -83,25 +82,21 @@ function scenarioSection(title, scenario) {
|
|
|
83
82
|
${blur(
|
|
84
83
|
scenario.behaviors.content?.blur,
|
|
85
84
|
scenario.behaviors.content?.noOverride,
|
|
86
|
-
)}
|
|
87
|
-
${alert(scenario.behaviors.content?.alert)}
|
|
85
|
+
)}${alert(scenario.behaviors.content?.alert)}
|
|
88
86
|
</td>
|
|
89
87
|
<td>
|
|
90
88
|
${blur(
|
|
91
89
|
scenario.behaviors.avatar?.blur,
|
|
92
90
|
scenario.behaviors.avatar?.noOverride,
|
|
93
|
-
)}
|
|
94
|
-
${alert(scenario.behaviors.avatar?.alert)}
|
|
91
|
+
)}${alert(scenario.behaviors.avatar?.alert)}
|
|
95
92
|
</td>
|
|
96
93
|
<td>
|
|
97
94
|
${blur(
|
|
98
95
|
scenario.behaviors.embed?.blur,
|
|
99
96
|
scenario.behaviors.embed?.noOverride,
|
|
100
|
-
)}
|
|
101
|
-
${alert(scenario.behaviors.embed?.alert)}
|
|
97
|
+
)}${alert(scenario.behaviors.embed?.alert)}
|
|
102
98
|
</td>
|
|
103
|
-
</tr
|
|
104
|
-
`
|
|
99
|
+
</tr>`
|
|
105
100
|
}
|
|
106
101
|
|
|
107
102
|
function filter(val) {
|
package/src/client/index.ts
CHANGED
|
@@ -8,6 +8,7 @@ import {
|
|
|
8
8
|
import { schemas } from './lexicons'
|
|
9
9
|
import { CID } from 'multiformats/cid'
|
|
10
10
|
import * as ComAtprotoAdminDefs from './types/com/atproto/admin/defs'
|
|
11
|
+
import * as ComAtprotoAdminDeleteAccount from './types/com/atproto/admin/deleteAccount'
|
|
11
12
|
import * as ComAtprotoAdminDisableAccountInvites from './types/com/atproto/admin/disableAccountInvites'
|
|
12
13
|
import * as ComAtprotoAdminDisableInviteCodes from './types/com/atproto/admin/disableInviteCodes'
|
|
13
14
|
import * as ComAtprotoAdminEmitModerationEvent from './types/com/atproto/admin/emitModerationEvent'
|
|
@@ -76,6 +77,9 @@ import * as ComAtprotoSyncNotifyOfUpdate from './types/com/atproto/sync/notifyOf
|
|
|
76
77
|
import * as ComAtprotoSyncRequestCrawl from './types/com/atproto/sync/requestCrawl'
|
|
77
78
|
import * as ComAtprotoSyncSubscribeRepos from './types/com/atproto/sync/subscribeRepos'
|
|
78
79
|
import * as ComAtprotoTempFetchLabels from './types/com/atproto/temp/fetchLabels'
|
|
80
|
+
import * as ComAtprotoTempImportRepo from './types/com/atproto/temp/importRepo'
|
|
81
|
+
import * as ComAtprotoTempPushBlob from './types/com/atproto/temp/pushBlob'
|
|
82
|
+
import * as ComAtprotoTempTransferAccount from './types/com/atproto/temp/transferAccount'
|
|
79
83
|
import * as AppBskyActorDefs from './types/app/bsky/actor/defs'
|
|
80
84
|
import * as AppBskyActorGetPreferences from './types/app/bsky/actor/getPreferences'
|
|
81
85
|
import * as AppBskyActorGetProfile from './types/app/bsky/actor/getProfile'
|
|
@@ -143,6 +147,7 @@ import * as AppBskyUnspeccedSearchActorsSkeleton from './types/app/bsky/unspecce
|
|
|
143
147
|
import * as AppBskyUnspeccedSearchPostsSkeleton from './types/app/bsky/unspecced/searchPostsSkeleton'
|
|
144
148
|
|
|
145
149
|
export * as ComAtprotoAdminDefs from './types/com/atproto/admin/defs'
|
|
150
|
+
export * as ComAtprotoAdminDeleteAccount from './types/com/atproto/admin/deleteAccount'
|
|
146
151
|
export * as ComAtprotoAdminDisableAccountInvites from './types/com/atproto/admin/disableAccountInvites'
|
|
147
152
|
export * as ComAtprotoAdminDisableInviteCodes from './types/com/atproto/admin/disableInviteCodes'
|
|
148
153
|
export * as ComAtprotoAdminEmitModerationEvent from './types/com/atproto/admin/emitModerationEvent'
|
|
@@ -211,6 +216,9 @@ export * as ComAtprotoSyncNotifyOfUpdate from './types/com/atproto/sync/notifyOf
|
|
|
211
216
|
export * as ComAtprotoSyncRequestCrawl from './types/com/atproto/sync/requestCrawl'
|
|
212
217
|
export * as ComAtprotoSyncSubscribeRepos from './types/com/atproto/sync/subscribeRepos'
|
|
213
218
|
export * as ComAtprotoTempFetchLabels from './types/com/atproto/temp/fetchLabels'
|
|
219
|
+
export * as ComAtprotoTempImportRepo from './types/com/atproto/temp/importRepo'
|
|
220
|
+
export * as ComAtprotoTempPushBlob from './types/com/atproto/temp/pushBlob'
|
|
221
|
+
export * as ComAtprotoTempTransferAccount from './types/com/atproto/temp/transferAccount'
|
|
214
222
|
export * as AppBskyActorDefs from './types/app/bsky/actor/defs'
|
|
215
223
|
export * as AppBskyActorGetPreferences from './types/app/bsky/actor/getPreferences'
|
|
216
224
|
export * as AppBskyActorGetProfile from './types/app/bsky/actor/getProfile'
|
|
@@ -366,6 +374,17 @@ export class AdminNS {
|
|
|
366
374
|
this._service = service
|
|
367
375
|
}
|
|
368
376
|
|
|
377
|
+
deleteAccount(
|
|
378
|
+
data?: ComAtprotoAdminDeleteAccount.InputSchema,
|
|
379
|
+
opts?: ComAtprotoAdminDeleteAccount.CallOptions,
|
|
380
|
+
): Promise<ComAtprotoAdminDeleteAccount.Response> {
|
|
381
|
+
return this._service.xrpc
|
|
382
|
+
.call('com.atproto.admin.deleteAccount', opts?.qp, data, opts)
|
|
383
|
+
.catch((e) => {
|
|
384
|
+
throw ComAtprotoAdminDeleteAccount.toKnownErr(e)
|
|
385
|
+
})
|
|
386
|
+
}
|
|
387
|
+
|
|
369
388
|
disableAccountInvites(
|
|
370
389
|
data?: ComAtprotoAdminDisableAccountInvites.InputSchema,
|
|
371
390
|
opts?: ComAtprotoAdminDisableAccountInvites.CallOptions,
|
|
@@ -1108,6 +1127,39 @@ export class TempNS {
|
|
|
1108
1127
|
throw ComAtprotoTempFetchLabels.toKnownErr(e)
|
|
1109
1128
|
})
|
|
1110
1129
|
}
|
|
1130
|
+
|
|
1131
|
+
importRepo(
|
|
1132
|
+
data?: ComAtprotoTempImportRepo.InputSchema,
|
|
1133
|
+
opts?: ComAtprotoTempImportRepo.CallOptions,
|
|
1134
|
+
): Promise<ComAtprotoTempImportRepo.Response> {
|
|
1135
|
+
return this._service.xrpc
|
|
1136
|
+
.call('com.atproto.temp.importRepo', opts?.qp, data, opts)
|
|
1137
|
+
.catch((e) => {
|
|
1138
|
+
throw ComAtprotoTempImportRepo.toKnownErr(e)
|
|
1139
|
+
})
|
|
1140
|
+
}
|
|
1141
|
+
|
|
1142
|
+
pushBlob(
|
|
1143
|
+
data?: ComAtprotoTempPushBlob.InputSchema,
|
|
1144
|
+
opts?: ComAtprotoTempPushBlob.CallOptions,
|
|
1145
|
+
): Promise<ComAtprotoTempPushBlob.Response> {
|
|
1146
|
+
return this._service.xrpc
|
|
1147
|
+
.call('com.atproto.temp.pushBlob', opts?.qp, data, opts)
|
|
1148
|
+
.catch((e) => {
|
|
1149
|
+
throw ComAtprotoTempPushBlob.toKnownErr(e)
|
|
1150
|
+
})
|
|
1151
|
+
}
|
|
1152
|
+
|
|
1153
|
+
transferAccount(
|
|
1154
|
+
data?: ComAtprotoTempTransferAccount.InputSchema,
|
|
1155
|
+
opts?: ComAtprotoTempTransferAccount.CallOptions,
|
|
1156
|
+
): Promise<ComAtprotoTempTransferAccount.Response> {
|
|
1157
|
+
return this._service.xrpc
|
|
1158
|
+
.call('com.atproto.temp.transferAccount', opts?.qp, data, opts)
|
|
1159
|
+
.catch((e) => {
|
|
1160
|
+
throw ComAtprotoTempTransferAccount.toKnownErr(e)
|
|
1161
|
+
})
|
|
1162
|
+
}
|
|
1111
1163
|
}
|
|
1112
1164
|
|
|
1113
1165
|
export class AppNS {
|
package/src/client/lexicons.ts
CHANGED
|
@@ -820,6 +820,29 @@ export const schemaDict = {
|
|
|
820
820
|
},
|
|
821
821
|
},
|
|
822
822
|
},
|
|
823
|
+
ComAtprotoAdminDeleteAccount: {
|
|
824
|
+
lexicon: 1,
|
|
825
|
+
id: 'com.atproto.admin.deleteAccount',
|
|
826
|
+
defs: {
|
|
827
|
+
main: {
|
|
828
|
+
type: 'procedure',
|
|
829
|
+
description: 'Delete a user account as an administrator.',
|
|
830
|
+
input: {
|
|
831
|
+
encoding: 'application/json',
|
|
832
|
+
schema: {
|
|
833
|
+
type: 'object',
|
|
834
|
+
required: ['did'],
|
|
835
|
+
properties: {
|
|
836
|
+
did: {
|
|
837
|
+
type: 'string',
|
|
838
|
+
format: 'did',
|
|
839
|
+
},
|
|
840
|
+
},
|
|
841
|
+
},
|
|
842
|
+
},
|
|
843
|
+
},
|
|
844
|
+
},
|
|
845
|
+
},
|
|
823
846
|
ComAtprotoAdminDisableAccountInvites: {
|
|
824
847
|
lexicon: 1,
|
|
825
848
|
id: 'com.atproto.admin.disableAccountInvites',
|
|
@@ -3979,6 +4002,135 @@ export const schemaDict = {
|
|
|
3979
4002
|
},
|
|
3980
4003
|
},
|
|
3981
4004
|
},
|
|
4005
|
+
ComAtprotoTempImportRepo: {
|
|
4006
|
+
lexicon: 1,
|
|
4007
|
+
id: 'com.atproto.temp.importRepo',
|
|
4008
|
+
defs: {
|
|
4009
|
+
main: {
|
|
4010
|
+
type: 'procedure',
|
|
4011
|
+
description:
|
|
4012
|
+
"Gets the did's repo, optionally catching up from a specific revision.",
|
|
4013
|
+
parameters: {
|
|
4014
|
+
type: 'params',
|
|
4015
|
+
required: ['did'],
|
|
4016
|
+
properties: {
|
|
4017
|
+
did: {
|
|
4018
|
+
type: 'string',
|
|
4019
|
+
format: 'did',
|
|
4020
|
+
description: 'The DID of the repo.',
|
|
4021
|
+
},
|
|
4022
|
+
},
|
|
4023
|
+
},
|
|
4024
|
+
input: {
|
|
4025
|
+
encoding: 'application/vnd.ipld.car',
|
|
4026
|
+
},
|
|
4027
|
+
output: {
|
|
4028
|
+
encoding: 'text/plain',
|
|
4029
|
+
},
|
|
4030
|
+
},
|
|
4031
|
+
},
|
|
4032
|
+
},
|
|
4033
|
+
ComAtprotoTempPushBlob: {
|
|
4034
|
+
lexicon: 1,
|
|
4035
|
+
id: 'com.atproto.temp.pushBlob',
|
|
4036
|
+
defs: {
|
|
4037
|
+
main: {
|
|
4038
|
+
type: 'procedure',
|
|
4039
|
+
description:
|
|
4040
|
+
"Gets the did's repo, optionally catching up from a specific revision.",
|
|
4041
|
+
parameters: {
|
|
4042
|
+
type: 'params',
|
|
4043
|
+
required: ['did'],
|
|
4044
|
+
properties: {
|
|
4045
|
+
did: {
|
|
4046
|
+
type: 'string',
|
|
4047
|
+
format: 'did',
|
|
4048
|
+
description: 'The DID of the repo.',
|
|
4049
|
+
},
|
|
4050
|
+
},
|
|
4051
|
+
},
|
|
4052
|
+
input: {
|
|
4053
|
+
encoding: '*/*',
|
|
4054
|
+
},
|
|
4055
|
+
},
|
|
4056
|
+
},
|
|
4057
|
+
},
|
|
4058
|
+
ComAtprotoTempTransferAccount: {
|
|
4059
|
+
lexicon: 1,
|
|
4060
|
+
id: 'com.atproto.temp.transferAccount',
|
|
4061
|
+
defs: {
|
|
4062
|
+
main: {
|
|
4063
|
+
type: 'procedure',
|
|
4064
|
+
description: 'Transfer an account.',
|
|
4065
|
+
input: {
|
|
4066
|
+
encoding: 'application/json',
|
|
4067
|
+
schema: {
|
|
4068
|
+
type: 'object',
|
|
4069
|
+
required: ['handle', 'did', 'plcOp'],
|
|
4070
|
+
properties: {
|
|
4071
|
+
handle: {
|
|
4072
|
+
type: 'string',
|
|
4073
|
+
format: 'handle',
|
|
4074
|
+
},
|
|
4075
|
+
did: {
|
|
4076
|
+
type: 'string',
|
|
4077
|
+
format: 'did',
|
|
4078
|
+
},
|
|
4079
|
+
plcOp: {
|
|
4080
|
+
type: 'unknown',
|
|
4081
|
+
},
|
|
4082
|
+
},
|
|
4083
|
+
},
|
|
4084
|
+
},
|
|
4085
|
+
output: {
|
|
4086
|
+
encoding: 'application/json',
|
|
4087
|
+
schema: {
|
|
4088
|
+
type: 'object',
|
|
4089
|
+
required: ['accessJwt', 'refreshJwt', 'handle', 'did'],
|
|
4090
|
+
properties: {
|
|
4091
|
+
accessJwt: {
|
|
4092
|
+
type: 'string',
|
|
4093
|
+
},
|
|
4094
|
+
refreshJwt: {
|
|
4095
|
+
type: 'string',
|
|
4096
|
+
},
|
|
4097
|
+
handle: {
|
|
4098
|
+
type: 'string',
|
|
4099
|
+
format: 'handle',
|
|
4100
|
+
},
|
|
4101
|
+
did: {
|
|
4102
|
+
type: 'string',
|
|
4103
|
+
format: 'did',
|
|
4104
|
+
},
|
|
4105
|
+
},
|
|
4106
|
+
},
|
|
4107
|
+
},
|
|
4108
|
+
errors: [
|
|
4109
|
+
{
|
|
4110
|
+
name: 'InvalidHandle',
|
|
4111
|
+
},
|
|
4112
|
+
{
|
|
4113
|
+
name: 'InvalidPassword',
|
|
4114
|
+
},
|
|
4115
|
+
{
|
|
4116
|
+
name: 'InvalidInviteCode',
|
|
4117
|
+
},
|
|
4118
|
+
{
|
|
4119
|
+
name: 'HandleNotAvailable',
|
|
4120
|
+
},
|
|
4121
|
+
{
|
|
4122
|
+
name: 'UnsupportedDomain',
|
|
4123
|
+
},
|
|
4124
|
+
{
|
|
4125
|
+
name: 'UnresolvableDid',
|
|
4126
|
+
},
|
|
4127
|
+
{
|
|
4128
|
+
name: 'IncompatibleDidDoc',
|
|
4129
|
+
},
|
|
4130
|
+
],
|
|
4131
|
+
},
|
|
4132
|
+
},
|
|
4133
|
+
},
|
|
3982
4134
|
AppBskyActorDefs: {
|
|
3983
4135
|
lexicon: 1,
|
|
3984
4136
|
id: 'app.bsky.actor.defs',
|
|
@@ -7671,6 +7823,7 @@ export const schemas: LexiconDoc[] = Object.values(schemaDict) as LexiconDoc[]
|
|
|
7671
7823
|
export const lexicons: Lexicons = new Lexicons(schemas)
|
|
7672
7824
|
export const ids = {
|
|
7673
7825
|
ComAtprotoAdminDefs: 'com.atproto.admin.defs',
|
|
7826
|
+
ComAtprotoAdminDeleteAccount: 'com.atproto.admin.deleteAccount',
|
|
7674
7827
|
ComAtprotoAdminDisableAccountInvites:
|
|
7675
7828
|
'com.atproto.admin.disableAccountInvites',
|
|
7676
7829
|
ComAtprotoAdminDisableInviteCodes: 'com.atproto.admin.disableInviteCodes',
|
|
@@ -7746,6 +7899,9 @@ export const ids = {
|
|
|
7746
7899
|
ComAtprotoSyncRequestCrawl: 'com.atproto.sync.requestCrawl',
|
|
7747
7900
|
ComAtprotoSyncSubscribeRepos: 'com.atproto.sync.subscribeRepos',
|
|
7748
7901
|
ComAtprotoTempFetchLabels: 'com.atproto.temp.fetchLabels',
|
|
7902
|
+
ComAtprotoTempImportRepo: 'com.atproto.temp.importRepo',
|
|
7903
|
+
ComAtprotoTempPushBlob: 'com.atproto.temp.pushBlob',
|
|
7904
|
+
ComAtprotoTempTransferAccount: 'com.atproto.temp.transferAccount',
|
|
7749
7905
|
AppBskyActorDefs: 'app.bsky.actor.defs',
|
|
7750
7906
|
AppBskyActorGetPreferences: 'app.bsky.actor.getPreferences',
|
|
7751
7907
|
AppBskyActorGetProfile: 'app.bsky.actor.getProfile',
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { Headers, XRPCError } from '@atproto/xrpc'
|
|
5
|
+
import { ValidationResult, BlobRef } from '@atproto/lexicon'
|
|
6
|
+
import { isObj, hasProp } from '../../../../util'
|
|
7
|
+
import { lexicons } from '../../../../lexicons'
|
|
8
|
+
import { CID } from 'multiformats/cid'
|
|
9
|
+
|
|
10
|
+
export interface QueryParams {}
|
|
11
|
+
|
|
12
|
+
export interface InputSchema {
|
|
13
|
+
did: string
|
|
14
|
+
[k: string]: unknown
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export interface CallOptions {
|
|
18
|
+
headers?: Headers
|
|
19
|
+
qp?: QueryParams
|
|
20
|
+
encoding: 'application/json'
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
export interface Response {
|
|
24
|
+
success: boolean
|
|
25
|
+
headers: Headers
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export function toKnownErr(e: any) {
|
|
29
|
+
if (e instanceof XRPCError) {
|
|
30
|
+
}
|
|
31
|
+
return e
|
|
32
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { Headers, XRPCError } from '@atproto/xrpc'
|
|
5
|
+
import { ValidationResult, BlobRef } from '@atproto/lexicon'
|
|
6
|
+
import { isObj, hasProp } from '../../../../util'
|
|
7
|
+
import { lexicons } from '../../../../lexicons'
|
|
8
|
+
import { CID } from 'multiformats/cid'
|
|
9
|
+
|
|
10
|
+
export interface QueryParams {
|
|
11
|
+
/** The DID of the repo. */
|
|
12
|
+
did: string
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export type InputSchema = string | Uint8Array
|
|
16
|
+
|
|
17
|
+
export interface CallOptions {
|
|
18
|
+
headers?: Headers
|
|
19
|
+
qp?: QueryParams
|
|
20
|
+
encoding: 'application/vnd.ipld.car'
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
export interface Response {
|
|
24
|
+
success: boolean
|
|
25
|
+
headers: Headers
|
|
26
|
+
data: Uint8Array
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export function toKnownErr(e: any) {
|
|
30
|
+
if (e instanceof XRPCError) {
|
|
31
|
+
}
|
|
32
|
+
return e
|
|
33
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { Headers, XRPCError } from '@atproto/xrpc'
|
|
5
|
+
import { ValidationResult, BlobRef } from '@atproto/lexicon'
|
|
6
|
+
import { isObj, hasProp } from '../../../../util'
|
|
7
|
+
import { lexicons } from '../../../../lexicons'
|
|
8
|
+
import { CID } from 'multiformats/cid'
|
|
9
|
+
|
|
10
|
+
export interface QueryParams {
|
|
11
|
+
/** The DID of the repo. */
|
|
12
|
+
did: string
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export type InputSchema = string | Uint8Array
|
|
16
|
+
|
|
17
|
+
export interface CallOptions {
|
|
18
|
+
headers?: Headers
|
|
19
|
+
qp?: QueryParams
|
|
20
|
+
encoding: string
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
export interface Response {
|
|
24
|
+
success: boolean
|
|
25
|
+
headers: Headers
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export function toKnownErr(e: any) {
|
|
29
|
+
if (e instanceof XRPCError) {
|
|
30
|
+
}
|
|
31
|
+
return e
|
|
32
|
+
}
|