@atproto/pds 0.3.16 → 0.3.17
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 +7 -0
- package/LICENSE.txt +1 -1
- package/dist/account-manager/helpers/email-token.d.ts +1 -0
- package/dist/account-manager/index.d.ts +0 -1
- package/dist/index.js +173 -147
- package/dist/index.js.map +3 -3
- package/dist/lexicon/index.d.ts +0 -2
- package/dist/lexicon/lexicons.d.ts +38 -47
- package/dist/lexicon/types/com/atproto/admin/defs.d.ts +2 -2
- package/dist/lexicon/types/com/atproto/admin/queryModerationEvents.d.ts +7 -0
- package/package.json +5 -5
- package/src/account-manager/helpers/email-token.ts +6 -0
- package/src/account-manager/index.ts +8 -12
- package/src/api/com/atproto/admin/sendEmail.ts +1 -1
- package/src/api/com/atproto/server/requestAccountDelete.ts +13 -0
- package/src/api/com/atproto/server/requestEmailConfirmation.ts +13 -0
- package/src/api/com/atproto/server/requestEmailUpdate.ts +13 -0
- package/src/api/com/atproto/server/requestPasswordReset.ts +33 -20
- package/src/api/com/atproto/server/updateEmail.ts +1 -1
- package/src/api/com/atproto/temp/index.ts +2 -0
- package/src/lexicon/index.ts +0 -12
- package/src/lexicon/lexicons.ts +43 -50
- package/src/lexicon/types/com/atproto/admin/defs.ts +2 -0
- package/src/lexicon/types/com/atproto/admin/queryModerationEvents.ts +13 -0
- package/tests/proxied/__snapshots__/feedgen.test.ts.snap +29 -802
- package/tests/proxied/feedgen.test.ts +26 -35
- package/dist/lexicon/types/app/bsky/unspecced/getTimelineSkeleton.d.ts +0 -35
- package/src/lexicon/types/app/bsky/unspecced/getTimelineSkeleton.ts +0 -49
package/dist/lexicon/index.d.ts
CHANGED
@@ -117,7 +117,6 @@ import * as AppBskyNotificationRegisterPush from './types/app/bsky/notification/
|
|
117
117
|
import * as AppBskyNotificationUpdateSeen from './types/app/bsky/notification/updateSeen';
|
118
118
|
import * as AppBskyUnspeccedGetPopularFeedGenerators from './types/app/bsky/unspecced/getPopularFeedGenerators';
|
119
119
|
import * as AppBskyUnspeccedGetTaggedSuggestions from './types/app/bsky/unspecced/getTaggedSuggestions';
|
120
|
-
import * as AppBskyUnspeccedGetTimelineSkeleton from './types/app/bsky/unspecced/getTimelineSkeleton';
|
121
120
|
import * as AppBskyUnspeccedSearchActorsSkeleton from './types/app/bsky/unspecced/searchActorsSkeleton';
|
122
121
|
import * as AppBskyUnspeccedSearchPostsSkeleton from './types/app/bsky/unspecced/searchPostsSkeleton';
|
123
122
|
export declare const COM_ATPROTO_ADMIN: {
|
@@ -355,7 +354,6 @@ export declare class AppBskyUnspeccedNS {
|
|
355
354
|
constructor(server: Server);
|
356
355
|
getPopularFeedGenerators<AV extends AuthVerifier>(cfg: ConfigOf<AV, AppBskyUnspeccedGetPopularFeedGenerators.Handler<ExtractAuth<AV>>, AppBskyUnspeccedGetPopularFeedGenerators.HandlerReqCtx<ExtractAuth<AV>>>): void;
|
357
356
|
getTaggedSuggestions<AV extends AuthVerifier>(cfg: ConfigOf<AV, AppBskyUnspeccedGetTaggedSuggestions.Handler<ExtractAuth<AV>>, AppBskyUnspeccedGetTaggedSuggestions.HandlerReqCtx<ExtractAuth<AV>>>): void;
|
358
|
-
getTimelineSkeleton<AV extends AuthVerifier>(cfg: ConfigOf<AV, AppBskyUnspeccedGetTimelineSkeleton.Handler<ExtractAuth<AV>>, AppBskyUnspeccedGetTimelineSkeleton.HandlerReqCtx<ExtractAuth<AV>>>): void;
|
359
357
|
searchActorsSkeleton<AV extends AuthVerifier>(cfg: ConfigOf<AV, AppBskyUnspeccedSearchActorsSkeleton.Handler<ExtractAuth<AV>>, AppBskyUnspeccedSearchActorsSkeleton.HandlerReqCtx<ExtractAuth<AV>>>): void;
|
360
358
|
searchPostsSkeleton<AV extends AuthVerifier>(cfg: ConfigOf<AV, AppBskyUnspeccedSearchPostsSkeleton.Handler<ExtractAuth<AV>>, AppBskyUnspeccedSearchPostsSkeleton.HandlerReqCtx<ExtractAuth<AV>>>): void;
|
361
359
|
}
|
@@ -1296,6 +1296,16 @@ export declare const schemaDict: {
|
|
1296
1296
|
enum: string[];
|
1297
1297
|
description: string;
|
1298
1298
|
};
|
1299
|
+
createdAfter: {
|
1300
|
+
type: string;
|
1301
|
+
format: string;
|
1302
|
+
description: string;
|
1303
|
+
};
|
1304
|
+
createdBefore: {
|
1305
|
+
type: string;
|
1306
|
+
format: string;
|
1307
|
+
description: string;
|
1308
|
+
};
|
1299
1309
|
subject: {
|
1300
1310
|
type: string;
|
1301
1311
|
format: string;
|
@@ -1311,6 +1321,34 @@ export declare const schemaDict: {
|
|
1311
1321
|
maximum: number;
|
1312
1322
|
default: number;
|
1313
1323
|
};
|
1324
|
+
hasComment: {
|
1325
|
+
type: string;
|
1326
|
+
description: string;
|
1327
|
+
};
|
1328
|
+
comment: {
|
1329
|
+
type: string;
|
1330
|
+
description: string;
|
1331
|
+
};
|
1332
|
+
addedLabels: {
|
1333
|
+
type: string;
|
1334
|
+
items: {
|
1335
|
+
type: string;
|
1336
|
+
};
|
1337
|
+
description: string;
|
1338
|
+
};
|
1339
|
+
removedLabels: {
|
1340
|
+
type: string;
|
1341
|
+
items: {
|
1342
|
+
type: string;
|
1343
|
+
};
|
1344
|
+
description: string;
|
1345
|
+
};
|
1346
|
+
reportTypes: {
|
1347
|
+
type: string;
|
1348
|
+
items: {
|
1349
|
+
type: string;
|
1350
|
+
};
|
1351
|
+
};
|
1314
1352
|
cursor: {
|
1315
1353
|
type: string;
|
1316
1354
|
};
|
@@ -7602,52 +7640,6 @@ export declare const schemaDict: {
|
|
7602
7640
|
};
|
7603
7641
|
};
|
7604
7642
|
};
|
7605
|
-
AppBskyUnspeccedGetTimelineSkeleton: {
|
7606
|
-
lexicon: number;
|
7607
|
-
id: string;
|
7608
|
-
defs: {
|
7609
|
-
main: {
|
7610
|
-
type: string;
|
7611
|
-
description: string;
|
7612
|
-
parameters: {
|
7613
|
-
type: string;
|
7614
|
-
properties: {
|
7615
|
-
limit: {
|
7616
|
-
type: string;
|
7617
|
-
minimum: number;
|
7618
|
-
maximum: number;
|
7619
|
-
default: number;
|
7620
|
-
};
|
7621
|
-
cursor: {
|
7622
|
-
type: string;
|
7623
|
-
};
|
7624
|
-
};
|
7625
|
-
};
|
7626
|
-
output: {
|
7627
|
-
encoding: string;
|
7628
|
-
schema: {
|
7629
|
-
type: string;
|
7630
|
-
required: string[];
|
7631
|
-
properties: {
|
7632
|
-
cursor: {
|
7633
|
-
type: string;
|
7634
|
-
};
|
7635
|
-
feed: {
|
7636
|
-
type: string;
|
7637
|
-
items: {
|
7638
|
-
type: string;
|
7639
|
-
ref: string;
|
7640
|
-
};
|
7641
|
-
};
|
7642
|
-
};
|
7643
|
-
};
|
7644
|
-
};
|
7645
|
-
errors: {
|
7646
|
-
name: string;
|
7647
|
-
}[];
|
7648
|
-
};
|
7649
|
-
};
|
7650
|
-
};
|
7651
7643
|
AppBskyUnspeccedSearchActorsSkeleton: {
|
7652
7644
|
lexicon: number;
|
7653
7645
|
id: string;
|
@@ -7911,7 +7903,6 @@ export declare const ids: {
|
|
7911
7903
|
AppBskyUnspeccedDefs: string;
|
7912
7904
|
AppBskyUnspeccedGetPopularFeedGenerators: string;
|
7913
7905
|
AppBskyUnspeccedGetTaggedSuggestions: string;
|
7914
|
-
AppBskyUnspeccedGetTimelineSkeleton: string;
|
7915
7906
|
AppBskyUnspeccedSearchActorsSkeleton: string;
|
7916
7907
|
AppBskyUnspeccedSearchPostsSkeleton: string;
|
7917
7908
|
};
|
@@ -12,7 +12,7 @@ export declare function isStatusAttr(v: unknown): v is StatusAttr;
|
|
12
12
|
export declare function validateStatusAttr(v: unknown): ValidationResult;
|
13
13
|
export interface ModEventView {
|
14
14
|
id: number;
|
15
|
-
event: ModEventTakedown | ModEventReverseTakedown | ModEventComment | ModEventReport | ModEventLabel | ModEventAcknowledge | ModEventEscalate | ModEventMute | ModEventEmail | {
|
15
|
+
event: ModEventTakedown | ModEventReverseTakedown | ModEventComment | ModEventReport | ModEventLabel | ModEventAcknowledge | ModEventEscalate | ModEventMute | ModEventEmail | ModEventResolveAppeal | {
|
16
16
|
$type: string;
|
17
17
|
[k: string]: unknown;
|
18
18
|
};
|
@@ -31,7 +31,7 @@ export declare function isModEventView(v: unknown): v is ModEventView;
|
|
31
31
|
export declare function validateModEventView(v: unknown): ValidationResult;
|
32
32
|
export interface ModEventViewDetail {
|
33
33
|
id: number;
|
34
|
-
event: ModEventTakedown | ModEventReverseTakedown | ModEventComment | ModEventReport | ModEventLabel | ModEventAcknowledge | ModEventEscalate | ModEventMute | ModEventResolveAppeal | {
|
34
|
+
event: ModEventTakedown | ModEventReverseTakedown | ModEventComment | ModEventReport | ModEventLabel | ModEventAcknowledge | ModEventEscalate | ModEventMute | ModEventEmail | ModEventResolveAppeal | {
|
35
35
|
$type: string;
|
36
36
|
[k: string]: unknown;
|
37
37
|
};
|
@@ -5,9 +5,16 @@ export interface QueryParams {
|
|
5
5
|
types?: string[];
|
6
6
|
createdBy?: string;
|
7
7
|
sortDirection: 'asc' | 'desc';
|
8
|
+
createdAfter?: string;
|
9
|
+
createdBefore?: string;
|
8
10
|
subject?: string;
|
9
11
|
includeAllUserRecords: boolean;
|
10
12
|
limit: number;
|
13
|
+
hasComment?: boolean;
|
14
|
+
comment?: string;
|
15
|
+
addedLabels?: string[];
|
16
|
+
removedLabels?: string[];
|
17
|
+
reportTypes?: string[];
|
11
18
|
cursor?: string;
|
12
19
|
}
|
13
20
|
export type InputSchema = undefined;
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@atproto/pds",
|
3
|
-
"version": "0.3.
|
3
|
+
"version": "0.3.17",
|
4
4
|
"license": "MIT",
|
5
5
|
"description": "Reference implementation of atproto Personal Data Server (PDS)",
|
6
6
|
"keywords": [
|
@@ -44,7 +44,7 @@
|
|
44
44
|
"typed-emitter": "^2.1.0",
|
45
45
|
"uint8arrays": "3.0.0",
|
46
46
|
"zod": "^3.21.4",
|
47
|
-
"@atproto/api": "^0.9.
|
47
|
+
"@atproto/api": "^0.9.6",
|
48
48
|
"@atproto/aws": "^0.1.6",
|
49
49
|
"@atproto/common": "^0.3.3",
|
50
50
|
"@atproto/crypto": "^0.3.0",
|
@@ -68,9 +68,9 @@
|
|
68
68
|
"axios": "^0.27.2",
|
69
69
|
"get-port": "^6.1.2",
|
70
70
|
"ws": "^8.12.0",
|
71
|
-
"@atproto/api": "^0.9.
|
72
|
-
"@atproto/bsky": "^0.0.
|
73
|
-
"@atproto/dev-env": "^0.2.
|
71
|
+
"@atproto/api": "^0.9.6",
|
72
|
+
"@atproto/bsky": "^0.0.29",
|
73
|
+
"@atproto/dev-env": "^0.2.29",
|
74
74
|
"@atproto/lex-cli": "^0.3.0"
|
75
75
|
},
|
76
76
|
"scripts": {
|
@@ -34,6 +34,12 @@ export const deleteEmailToken = async (
|
|
34
34
|
)
|
35
35
|
}
|
36
36
|
|
37
|
+
export const deleteAllEmailTokens = async (db: AccountDb, did: string) => {
|
38
|
+
await db.executeWithRetry(
|
39
|
+
db.db.deleteFrom('email_token').where('did', '=', did),
|
40
|
+
)
|
41
|
+
}
|
42
|
+
|
37
43
|
export const assertValidToken = async (
|
38
44
|
db: AccountDb,
|
39
45
|
did: string,
|
@@ -321,18 +321,14 @@ export class AccountManager {
|
|
321
321
|
)
|
322
322
|
}
|
323
323
|
|
324
|
-
async updateEmail(opts: { did: string; email: string
|
325
|
-
const { did, email
|
326
|
-
|
327
|
-
|
328
|
-
|
329
|
-
|
330
|
-
|
331
|
-
|
332
|
-
)
|
333
|
-
} else {
|
334
|
-
return account.updateEmail(this.db, did, email)
|
335
|
-
}
|
324
|
+
async updateEmail(opts: { did: string; email: string }) {
|
325
|
+
const { did, email } = opts
|
326
|
+
await this.db.transaction((dbTxn) =>
|
327
|
+
Promise.all([
|
328
|
+
account.updateEmail(dbTxn, did, email),
|
329
|
+
emailToken.deleteAllEmailTokens(dbTxn, did),
|
330
|
+
]),
|
331
|
+
)
|
336
332
|
}
|
337
333
|
|
338
334
|
async resetPassword(opts: { password: string; token: string }) {
|
@@ -40,7 +40,7 @@ export default function (server: Server, ctx: AppContext) {
|
|
40
40
|
{ content },
|
41
41
|
{ subject, to: account.email },
|
42
42
|
)
|
43
|
-
await ctx.
|
43
|
+
await ctx.moderationAgent.api.com.atproto.admin.emitModerationEvent(
|
44
44
|
{
|
45
45
|
event: {
|
46
46
|
$type: 'com.atproto.admin.defs#modEventEmail',
|
@@ -1,3 +1,4 @@
|
|
1
|
+
import { DAY, HOUR } from '@atproto/common'
|
1
2
|
import { InvalidRequestError } from '@atproto/xrpc-server'
|
2
3
|
import { Server } from '../../../../lexicon'
|
3
4
|
import AppContext from '../../../../context'
|
@@ -5,6 +6,18 @@ import { authPassthru } from '../../../proxy'
|
|
5
6
|
|
6
7
|
export default function (server: Server, ctx: AppContext) {
|
7
8
|
server.com.atproto.server.requestAccountDelete({
|
9
|
+
rateLimit: [
|
10
|
+
{
|
11
|
+
durationMs: DAY,
|
12
|
+
points: 15,
|
13
|
+
calcKey: ({ auth }) => auth.credentials.did,
|
14
|
+
},
|
15
|
+
{
|
16
|
+
durationMs: HOUR,
|
17
|
+
points: 5,
|
18
|
+
calcKey: ({ auth }) => auth.credentials.did,
|
19
|
+
},
|
20
|
+
],
|
8
21
|
auth: ctx.authVerifier.accessCheckTakedown,
|
9
22
|
handler: async ({ auth, req }) => {
|
10
23
|
const did = auth.credentials.did
|
@@ -1,3 +1,4 @@
|
|
1
|
+
import { DAY, HOUR } from '@atproto/common'
|
1
2
|
import { InvalidRequestError } from '@atproto/xrpc-server'
|
2
3
|
import { Server } from '../../../../lexicon'
|
3
4
|
import AppContext from '../../../../context'
|
@@ -5,6 +6,18 @@ import { authPassthru } from '../../../proxy'
|
|
5
6
|
|
6
7
|
export default function (server: Server, ctx: AppContext) {
|
7
8
|
server.com.atproto.server.requestEmailConfirmation({
|
9
|
+
rateLimit: [
|
10
|
+
{
|
11
|
+
durationMs: DAY,
|
12
|
+
points: 15,
|
13
|
+
calcKey: ({ auth }) => auth.credentials.did,
|
14
|
+
},
|
15
|
+
{
|
16
|
+
durationMs: HOUR,
|
17
|
+
points: 5,
|
18
|
+
calcKey: ({ auth }) => auth.credentials.did,
|
19
|
+
},
|
20
|
+
],
|
8
21
|
auth: ctx.authVerifier.accessCheckTakedown,
|
9
22
|
handler: async ({ auth, req }) => {
|
10
23
|
const did = auth.credentials.did
|
@@ -1,3 +1,4 @@
|
|
1
|
+
import { DAY, HOUR } from '@atproto/common'
|
1
2
|
import { InvalidRequestError } from '@atproto/xrpc-server'
|
2
3
|
import { Server } from '../../../../lexicon'
|
3
4
|
import AppContext from '../../../../context'
|
@@ -5,6 +6,18 @@ import { authPassthru, resultPassthru } from '../../../proxy'
|
|
5
6
|
|
6
7
|
export default function (server: Server, ctx: AppContext) {
|
7
8
|
server.com.atproto.server.requestEmailUpdate({
|
9
|
+
rateLimit: [
|
10
|
+
{
|
11
|
+
durationMs: DAY,
|
12
|
+
points: 15,
|
13
|
+
calcKey: ({ auth }) => auth.credentials.did,
|
14
|
+
},
|
15
|
+
{
|
16
|
+
durationMs: HOUR,
|
17
|
+
points: 5,
|
18
|
+
calcKey: ({ auth }) => auth.credentials.did,
|
19
|
+
},
|
20
|
+
],
|
8
21
|
auth: ctx.authVerifier.accessCheckTakedown,
|
9
22
|
handler: async ({ auth, req }) => {
|
10
23
|
const did = auth.credentials.did
|
@@ -1,32 +1,45 @@
|
|
1
|
+
import { DAY, HOUR } from '@atproto/common'
|
1
2
|
import { InvalidRequestError } from '@atproto/xrpc-server'
|
2
3
|
import AppContext from '../../../../context'
|
3
4
|
import { Server } from '../../../../lexicon'
|
4
5
|
import { authPassthru } from '../../../proxy'
|
5
6
|
|
6
7
|
export default function (server: Server, ctx: AppContext) {
|
7
|
-
server.com.atproto.server.requestPasswordReset(
|
8
|
-
|
8
|
+
server.com.atproto.server.requestPasswordReset({
|
9
|
+
rateLimit: [
|
10
|
+
{
|
11
|
+
durationMs: DAY,
|
12
|
+
points: 50,
|
13
|
+
},
|
14
|
+
{
|
15
|
+
durationMs: HOUR,
|
16
|
+
points: 15,
|
17
|
+
},
|
18
|
+
],
|
19
|
+
handler: async ({ input, req }) => {
|
20
|
+
const email = input.body.email.toLowerCase()
|
9
21
|
|
10
|
-
|
22
|
+
const account = await ctx.accountManager.getAccountByEmail(email)
|
11
23
|
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
24
|
+
if (!account?.email) {
|
25
|
+
if (ctx.entrywayAgent) {
|
26
|
+
await ctx.entrywayAgent.com.atproto.server.requestPasswordReset(
|
27
|
+
input.body,
|
28
|
+
authPassthru(req, true),
|
29
|
+
)
|
30
|
+
return
|
31
|
+
}
|
32
|
+
throw new InvalidRequestError('account does not have an email address')
|
19
33
|
}
|
20
|
-
throw new InvalidRequestError('account does not have an email address')
|
21
|
-
}
|
22
34
|
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
35
|
+
const token = await ctx.accountManager.createEmailToken(
|
36
|
+
account.did,
|
37
|
+
'reset_password',
|
38
|
+
)
|
39
|
+
await ctx.mailer.sendResetPassword(
|
40
|
+
{ identifier: account.handle ?? account.email, token },
|
41
|
+
{ to: account.email },
|
42
|
+
)
|
43
|
+
},
|
31
44
|
})
|
32
45
|
}
|
@@ -45,7 +45,7 @@ export default function (server: Server, ctx: AppContext) {
|
|
45
45
|
}
|
46
46
|
|
47
47
|
try {
|
48
|
-
await ctx.accountManager.updateEmail({ did, email
|
48
|
+
await ctx.accountManager.updateEmail({ did, email })
|
49
49
|
} catch (err) {
|
50
50
|
if (err instanceof UserAlreadyExistsError) {
|
51
51
|
throw new InvalidRequestError(
|
@@ -1,10 +1,12 @@
|
|
1
1
|
import AppContext from '../../../../context'
|
2
2
|
import { Server } from '../../../../lexicon'
|
3
|
+
import checkSignupQueue from './checkSignupQueue'
|
3
4
|
import importRepo from './importRepo'
|
4
5
|
import pushBlob from './pushBlob'
|
5
6
|
import transferAccount from './transferAccount'
|
6
7
|
|
7
8
|
export default function (server: Server, ctx: AppContext) {
|
9
|
+
checkSignupQueue(server, ctx)
|
8
10
|
importRepo(server, ctx)
|
9
11
|
pushBlob(server, ctx)
|
10
12
|
transferAccount(server, ctx)
|
package/src/lexicon/index.ts
CHANGED
@@ -127,7 +127,6 @@ import * as AppBskyNotificationRegisterPush from './types/app/bsky/notification/
|
|
127
127
|
import * as AppBskyNotificationUpdateSeen from './types/app/bsky/notification/updateSeen'
|
128
128
|
import * as AppBskyUnspeccedGetPopularFeedGenerators from './types/app/bsky/unspecced/getPopularFeedGenerators'
|
129
129
|
import * as AppBskyUnspeccedGetTaggedSuggestions from './types/app/bsky/unspecced/getTaggedSuggestions'
|
130
|
-
import * as AppBskyUnspeccedGetTimelineSkeleton from './types/app/bsky/unspecced/getTimelineSkeleton'
|
131
130
|
import * as AppBskyUnspeccedSearchActorsSkeleton from './types/app/bsky/unspecced/searchActorsSkeleton'
|
132
131
|
import * as AppBskyUnspeccedSearchPostsSkeleton from './types/app/bsky/unspecced/searchPostsSkeleton'
|
133
132
|
|
@@ -1649,17 +1648,6 @@ export class AppBskyUnspeccedNS {
|
|
1649
1648
|
return this._server.xrpc.method(nsid, cfg)
|
1650
1649
|
}
|
1651
1650
|
|
1652
|
-
getTimelineSkeleton<AV extends AuthVerifier>(
|
1653
|
-
cfg: ConfigOf<
|
1654
|
-
AV,
|
1655
|
-
AppBskyUnspeccedGetTimelineSkeleton.Handler<ExtractAuth<AV>>,
|
1656
|
-
AppBskyUnspeccedGetTimelineSkeleton.HandlerReqCtx<ExtractAuth<AV>>
|
1657
|
-
>,
|
1658
|
-
) {
|
1659
|
-
const nsid = 'app.bsky.unspecced.getTimelineSkeleton' // @ts-ignore
|
1660
|
-
return this._server.xrpc.method(nsid, cfg)
|
1661
|
-
}
|
1662
|
-
|
1663
1651
|
searchActorsSkeleton<AV extends AuthVerifier>(
|
1664
1652
|
cfg: ConfigOf<
|
1665
1653
|
AV,
|
package/src/lexicon/lexicons.ts
CHANGED
@@ -91,6 +91,7 @@ export const schemaDict = {
|
|
91
91
|
'lex:com.atproto.admin.defs#modEventEscalate',
|
92
92
|
'lex:com.atproto.admin.defs#modEventMute',
|
93
93
|
'lex:com.atproto.admin.defs#modEventEmail',
|
94
|
+
'lex:com.atproto.admin.defs#modEventResolveAppeal',
|
94
95
|
],
|
95
96
|
},
|
96
97
|
subject: {
|
@@ -147,6 +148,7 @@ export const schemaDict = {
|
|
147
148
|
'lex:com.atproto.admin.defs#modEventAcknowledge',
|
148
149
|
'lex:com.atproto.admin.defs#modEventEscalate',
|
149
150
|
'lex:com.atproto.admin.defs#modEventMute',
|
151
|
+
'lex:com.atproto.admin.defs#modEventEmail',
|
150
152
|
'lex:com.atproto.admin.defs#modEventResolveAppeal',
|
151
153
|
],
|
152
154
|
},
|
@@ -1450,6 +1452,16 @@ export const schemaDict = {
|
|
1450
1452
|
description:
|
1451
1453
|
'Sort direction for the events. Defaults to descending order of created at timestamp.',
|
1452
1454
|
},
|
1455
|
+
createdAfter: {
|
1456
|
+
type: 'string',
|
1457
|
+
format: 'datetime',
|
1458
|
+
description: 'Retrieve events created after a given timestamp',
|
1459
|
+
},
|
1460
|
+
createdBefore: {
|
1461
|
+
type: 'string',
|
1462
|
+
format: 'datetime',
|
1463
|
+
description: 'Retrieve events created before a given timestamp',
|
1464
|
+
},
|
1453
1465
|
subject: {
|
1454
1466
|
type: 'string',
|
1455
1467
|
format: 'uri',
|
@@ -1466,6 +1478,37 @@ export const schemaDict = {
|
|
1466
1478
|
maximum: 100,
|
1467
1479
|
default: 50,
|
1468
1480
|
},
|
1481
|
+
hasComment: {
|
1482
|
+
type: 'boolean',
|
1483
|
+
description: 'If true, only events with comments are returned',
|
1484
|
+
},
|
1485
|
+
comment: {
|
1486
|
+
type: 'string',
|
1487
|
+
description:
|
1488
|
+
'If specified, only events with comments containing the keyword are returned',
|
1489
|
+
},
|
1490
|
+
addedLabels: {
|
1491
|
+
type: 'array',
|
1492
|
+
items: {
|
1493
|
+
type: 'string',
|
1494
|
+
},
|
1495
|
+
description:
|
1496
|
+
'If specified, only events where all of these labels were added are returned',
|
1497
|
+
},
|
1498
|
+
removedLabels: {
|
1499
|
+
type: 'array',
|
1500
|
+
items: {
|
1501
|
+
type: 'string',
|
1502
|
+
},
|
1503
|
+
description:
|
1504
|
+
'If specified, only events where all of these labels were removed are returned',
|
1505
|
+
},
|
1506
|
+
reportTypes: {
|
1507
|
+
type: 'array',
|
1508
|
+
items: {
|
1509
|
+
type: 'string',
|
1510
|
+
},
|
1511
|
+
},
|
1469
1512
|
cursor: {
|
1470
1513
|
type: 'string',
|
1471
1514
|
},
|
@@ -8100,55 +8143,6 @@ export const schemaDict = {
|
|
8100
8143
|
},
|
8101
8144
|
},
|
8102
8145
|
},
|
8103
|
-
AppBskyUnspeccedGetTimelineSkeleton: {
|
8104
|
-
lexicon: 1,
|
8105
|
-
id: 'app.bsky.unspecced.getTimelineSkeleton',
|
8106
|
-
defs: {
|
8107
|
-
main: {
|
8108
|
-
type: 'query',
|
8109
|
-
description:
|
8110
|
-
'DEPRECATED: a skeleton of a timeline. Unspecced and will be unavailable soon.',
|
8111
|
-
parameters: {
|
8112
|
-
type: 'params',
|
8113
|
-
properties: {
|
8114
|
-
limit: {
|
8115
|
-
type: 'integer',
|
8116
|
-
minimum: 1,
|
8117
|
-
maximum: 100,
|
8118
|
-
default: 50,
|
8119
|
-
},
|
8120
|
-
cursor: {
|
8121
|
-
type: 'string',
|
8122
|
-
},
|
8123
|
-
},
|
8124
|
-
},
|
8125
|
-
output: {
|
8126
|
-
encoding: 'application/json',
|
8127
|
-
schema: {
|
8128
|
-
type: 'object',
|
8129
|
-
required: ['feed'],
|
8130
|
-
properties: {
|
8131
|
-
cursor: {
|
8132
|
-
type: 'string',
|
8133
|
-
},
|
8134
|
-
feed: {
|
8135
|
-
type: 'array',
|
8136
|
-
items: {
|
8137
|
-
type: 'ref',
|
8138
|
-
ref: 'lex:app.bsky.feed.defs#skeletonFeedPost',
|
8139
|
-
},
|
8140
|
-
},
|
8141
|
-
},
|
8142
|
-
},
|
8143
|
-
},
|
8144
|
-
errors: [
|
8145
|
-
{
|
8146
|
-
name: 'UnknownFeed',
|
8147
|
-
},
|
8148
|
-
],
|
8149
|
-
},
|
8150
|
-
},
|
8151
|
-
},
|
8152
8146
|
AppBskyUnspeccedSearchActorsSkeleton: {
|
8153
8147
|
lexicon: 1,
|
8154
8148
|
id: 'app.bsky.unspecced.searchActorsSkeleton',
|
@@ -8438,7 +8432,6 @@ export const ids = {
|
|
8438
8432
|
'app.bsky.unspecced.getPopularFeedGenerators',
|
8439
8433
|
AppBskyUnspeccedGetTaggedSuggestions:
|
8440
8434
|
'app.bsky.unspecced.getTaggedSuggestions',
|
8441
|
-
AppBskyUnspeccedGetTimelineSkeleton: 'app.bsky.unspecced.getTimelineSkeleton',
|
8442
8435
|
AppBskyUnspeccedSearchActorsSkeleton:
|
8443
8436
|
'app.bsky.unspecced.searchActorsSkeleton',
|
8444
8437
|
AppBskyUnspeccedSearchPostsSkeleton: 'app.bsky.unspecced.searchPostsSkeleton',
|
@@ -40,6 +40,7 @@ export interface ModEventView {
|
|
40
40
|
| ModEventEscalate
|
41
41
|
| ModEventMute
|
42
42
|
| ModEventEmail
|
43
|
+
| ModEventResolveAppeal
|
43
44
|
| { $type: string; [k: string]: unknown }
|
44
45
|
subject:
|
45
46
|
| RepoRef
|
@@ -76,6 +77,7 @@ export interface ModEventViewDetail {
|
|
76
77
|
| ModEventAcknowledge
|
77
78
|
| ModEventEscalate
|
78
79
|
| ModEventMute
|
80
|
+
| ModEventEmail
|
79
81
|
| ModEventResolveAppeal
|
80
82
|
| { $type: string; [k: string]: unknown }
|
81
83
|
subject:
|
@@ -15,10 +15,23 @@ export interface QueryParams {
|
|
15
15
|
createdBy?: string
|
16
16
|
/** Sort direction for the events. Defaults to descending order of created at timestamp. */
|
17
17
|
sortDirection: 'asc' | 'desc'
|
18
|
+
/** Retrieve events created after a given timestamp */
|
19
|
+
createdAfter?: string
|
20
|
+
/** Retrieve events created before a given timestamp */
|
21
|
+
createdBefore?: string
|
18
22
|
subject?: string
|
19
23
|
/** If true, events on all record types (posts, lists, profile etc.) owned by the did are returned */
|
20
24
|
includeAllUserRecords: boolean
|
21
25
|
limit: number
|
26
|
+
/** If true, only events with comments are returned */
|
27
|
+
hasComment?: boolean
|
28
|
+
/** If specified, only events with comments containing the keyword are returned */
|
29
|
+
comment?: string
|
30
|
+
/** If specified, only events where all of these labels were added are returned */
|
31
|
+
addedLabels?: string[]
|
32
|
+
/** If specified, only events where all of these labels were removed are returned */
|
33
|
+
removedLabels?: string[]
|
34
|
+
reportTypes?: string[]
|
22
35
|
cursor?: string
|
23
36
|
}
|
24
37
|
|