@atproto/pds 0.4.60 → 0.4.62
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 +26 -0
- package/dist/account-manager/helpers/account.d.ts +1 -0
- package/dist/account-manager/helpers/account.d.ts.map +1 -1
- package/dist/account-manager/helpers/account.js +15 -1
- package/dist/account-manager/helpers/account.js.map +1 -1
- package/dist/account-manager/helpers/invite.d.ts +1 -1
- package/dist/account-manager/helpers/invite.d.ts.map +1 -1
- package/dist/account-manager/helpers/invite.js +20 -9
- package/dist/account-manager/helpers/invite.js.map +1 -1
- package/dist/account-manager/helpers/token.d.ts +16 -16
- package/dist/account-manager/index.d.ts +2 -0
- package/dist/account-manager/index.d.ts.map +1 -1
- package/dist/account-manager/index.js +8 -1
- package/dist/account-manager/index.js.map +1 -1
- package/dist/api/com/atproto/admin/getAccountInfo.d.ts.map +1 -1
- package/dist/api/com/atproto/admin/getAccountInfo.js +6 -14
- package/dist/api/com/atproto/admin/getAccountInfo.js.map +1 -1
- package/dist/api/com/atproto/admin/getAccountInfos.d.ts +4 -0
- package/dist/api/com/atproto/admin/getAccountInfos.d.ts.map +1 -0
- package/dist/api/com/atproto/admin/getAccountInfos.js +32 -0
- package/dist/api/com/atproto/admin/getAccountInfos.js.map +1 -0
- package/dist/api/com/atproto/admin/index.d.ts.map +1 -1
- package/dist/api/com/atproto/admin/index.js +2 -0
- package/dist/api/com/atproto/admin/index.js.map +1 -1
- package/dist/api/com/atproto/admin/util.d.ts +17 -0
- package/dist/api/com/atproto/admin/util.d.ts.map +1 -1
- package/dist/api/com/atproto/admin/util.js +27 -1
- package/dist/api/com/atproto/admin/util.js.map +1 -1
- package/dist/api/com/atproto/repo/getRecord.d.ts.map +1 -1
- package/dist/api/com/atproto/repo/getRecord.js +1 -1
- package/dist/api/com/atproto/repo/getRecord.js.map +1 -1
- package/dist/config/config.d.ts +8 -0
- package/dist/config/config.d.ts.map +1 -1
- package/dist/config/config.js +1 -0
- package/dist/config/config.js.map +1 -1
- package/dist/config/env.d.ts +1 -0
- package/dist/config/env.d.ts.map +1 -1
- package/dist/config/env.js +1 -0
- package/dist/config/env.js.map +1 -1
- package/dist/lexicon/index.d.ts +15 -0
- package/dist/lexicon/index.d.ts.map +1 -1
- package/dist/lexicon/index.js +40 -1
- package/dist/lexicon/index.js.map +1 -1
- package/dist/lexicon/lexicons.d.ts +261 -0
- package/dist/lexicon/lexicons.d.ts.map +1 -1
- package/dist/lexicon/lexicons.js +269 -0
- package/dist/lexicon/lexicons.js.map +1 -1
- package/dist/lexicon/types/com/atproto/repo/getRecord.d.ts +1 -0
- package/dist/lexicon/types/com/atproto/repo/getRecord.d.ts.map +1 -1
- package/dist/lexicon/types/tools/ozone/moderation/getRecords.d.ts +39 -0
- package/dist/lexicon/types/tools/ozone/moderation/getRecords.d.ts.map +1 -0
- package/dist/lexicon/types/tools/ozone/moderation/getRecords.js +3 -0
- package/dist/lexicon/types/tools/ozone/moderation/getRecords.js.map +1 -0
- package/dist/lexicon/types/tools/ozone/moderation/getRepos.d.ts +39 -0
- package/dist/lexicon/types/tools/ozone/moderation/getRepos.d.ts.map +1 -0
- package/dist/lexicon/types/tools/ozone/moderation/getRepos.js +3 -0
- package/dist/lexicon/types/tools/ozone/moderation/getRepos.js.map +1 -0
- package/dist/lexicon/types/tools/ozone/signature/defs.d.ts +12 -0
- package/dist/lexicon/types/tools/ozone/signature/defs.d.ts.map +1 -0
- package/dist/lexicon/types/tools/ozone/signature/defs.js +16 -0
- package/dist/lexicon/types/tools/ozone/signature/defs.js.map +1 -0
- package/dist/lexicon/types/tools/ozone/signature/findCorrelation.d.ts +36 -0
- package/dist/lexicon/types/tools/ozone/signature/findCorrelation.d.ts.map +1 -0
- package/dist/lexicon/types/tools/ozone/signature/findCorrelation.js +3 -0
- package/dist/lexicon/types/tools/ozone/signature/findCorrelation.js.map +1 -0
- package/dist/lexicon/types/tools/ozone/signature/findRelatedAccounts.d.ts +48 -0
- package/dist/lexicon/types/tools/ozone/signature/findRelatedAccounts.d.ts.map +1 -0
- package/dist/lexicon/types/tools/ozone/signature/findRelatedAccounts.js +16 -0
- package/dist/lexicon/types/tools/ozone/signature/findRelatedAccounts.js.map +1 -0
- package/dist/lexicon/types/tools/ozone/signature/searchAccounts.d.ts +39 -0
- package/dist/lexicon/types/tools/ozone/signature/searchAccounts.d.ts.map +1 -0
- package/dist/lexicon/types/tools/ozone/signature/searchAccounts.js +3 -0
- package/dist/lexicon/types/tools/ozone/signature/searchAccounts.js.map +1 -0
- package/dist/mailer/templates/confirm-email.js +1 -1
- package/dist/mailer/templates/confirm-email.js.map +1 -1
- package/dist/mailer/templates/delete-account.js +1 -1
- package/dist/mailer/templates/delete-account.js.map +1 -1
- package/dist/mailer/templates/plc-operation.js +1 -1
- package/dist/mailer/templates/plc-operation.js.map +1 -1
- package/dist/mailer/templates/reset-password.js +1 -1
- package/dist/mailer/templates/reset-password.js.map +1 -1
- package/dist/mailer/templates/update-email.js +1 -1
- package/dist/mailer/templates/update-email.js.map +1 -1
- package/dist/pipethrough.d.ts +1 -1
- package/dist/pipethrough.d.ts.map +1 -1
- package/dist/pipethrough.js +105 -73
- package/dist/pipethrough.js.map +1 -1
- package/package.json +11 -11
- package/src/account-manager/helpers/account.ts +22 -0
- package/src/account-manager/helpers/invite.ts +19 -9
- package/src/account-manager/index.ts +13 -1
- package/src/api/com/atproto/admin/getAccountInfo.ts +6 -13
- package/src/api/com/atproto/admin/getAccountInfos.ts +33 -0
- package/src/api/com/atproto/admin/index.ts +2 -0
- package/src/api/com/atproto/admin/util.ts +38 -0
- package/src/api/com/atproto/repo/getRecord.ts +4 -1
- package/src/config/config.ts +10 -0
- package/src/config/env.ts +2 -0
- package/src/lexicon/index.ts +70 -0
- package/src/lexicon/lexicons.ts +273 -0
- package/src/lexicon/types/com/atproto/repo/getRecord.ts +1 -0
- package/src/lexicon/types/tools/ozone/moderation/getRecords.ts +50 -0
- package/src/lexicon/types/tools/ozone/moderation/getRepos.ts +50 -0
- package/src/lexicon/types/tools/ozone/signature/defs.ts +25 -0
- package/src/lexicon/types/tools/ozone/signature/findCorrelation.ts +46 -0
- package/src/lexicon/types/tools/ozone/signature/findRelatedAccounts.ts +71 -0
- package/src/lexicon/types/tools/ozone/signature/searchAccounts.ts +49 -0
- package/src/mailer/templates/confirm-email.hbs +1 -1
- package/src/mailer/templates/delete-account.hbs +1 -1
- package/src/mailer/templates/plc-operation.hbs +1 -1
- package/src/mailer/templates/reset-password.hbs +1 -1
- package/src/mailer/templates/update-email.hbs +1 -1
- package/src/pipethrough.ts +131 -92
- package/tests/proxied/read-after-write.test.ts +77 -0
package/src/lexicon/index.ts
CHANGED
@@ -166,11 +166,16 @@ import * as ToolsOzoneCommunicationUpdateTemplate from './types/tools/ozone/comm
|
|
166
166
|
import * as ToolsOzoneModerationEmitEvent from './types/tools/ozone/moderation/emitEvent'
|
167
167
|
import * as ToolsOzoneModerationGetEvent from './types/tools/ozone/moderation/getEvent'
|
168
168
|
import * as ToolsOzoneModerationGetRecord from './types/tools/ozone/moderation/getRecord'
|
169
|
+
import * as ToolsOzoneModerationGetRecords from './types/tools/ozone/moderation/getRecords'
|
169
170
|
import * as ToolsOzoneModerationGetRepo from './types/tools/ozone/moderation/getRepo'
|
171
|
+
import * as ToolsOzoneModerationGetRepos from './types/tools/ozone/moderation/getRepos'
|
170
172
|
import * as ToolsOzoneModerationQueryEvents from './types/tools/ozone/moderation/queryEvents'
|
171
173
|
import * as ToolsOzoneModerationQueryStatuses from './types/tools/ozone/moderation/queryStatuses'
|
172
174
|
import * as ToolsOzoneModerationSearchRepos from './types/tools/ozone/moderation/searchRepos'
|
173
175
|
import * as ToolsOzoneServerGetConfig from './types/tools/ozone/server/getConfig'
|
176
|
+
import * as ToolsOzoneSignatureFindCorrelation from './types/tools/ozone/signature/findCorrelation'
|
177
|
+
import * as ToolsOzoneSignatureFindRelatedAccounts from './types/tools/ozone/signature/findRelatedAccounts'
|
178
|
+
import * as ToolsOzoneSignatureSearchAccounts from './types/tools/ozone/signature/searchAccounts'
|
174
179
|
import * as ToolsOzoneTeamAddMember from './types/tools/ozone/team/addMember'
|
175
180
|
import * as ToolsOzoneTeamDeleteMember from './types/tools/ozone/team/deleteMember'
|
176
181
|
import * as ToolsOzoneTeamListMembers from './types/tools/ozone/team/listMembers'
|
@@ -2159,6 +2164,7 @@ export class ToolsOzoneNS {
|
|
2159
2164
|
communication: ToolsOzoneCommunicationNS
|
2160
2165
|
moderation: ToolsOzoneModerationNS
|
2161
2166
|
server: ToolsOzoneServerNS
|
2167
|
+
signature: ToolsOzoneSignatureNS
|
2162
2168
|
team: ToolsOzoneTeamNS
|
2163
2169
|
|
2164
2170
|
constructor(server: Server) {
|
@@ -2166,6 +2172,7 @@ export class ToolsOzoneNS {
|
|
2166
2172
|
this.communication = new ToolsOzoneCommunicationNS(server)
|
2167
2173
|
this.moderation = new ToolsOzoneModerationNS(server)
|
2168
2174
|
this.server = new ToolsOzoneServerNS(server)
|
2175
|
+
this.signature = new ToolsOzoneSignatureNS(server)
|
2169
2176
|
this.team = new ToolsOzoneTeamNS(server)
|
2170
2177
|
}
|
2171
2178
|
}
|
@@ -2262,6 +2269,17 @@ export class ToolsOzoneModerationNS {
|
|
2262
2269
|
return this._server.xrpc.method(nsid, cfg)
|
2263
2270
|
}
|
2264
2271
|
|
2272
|
+
getRecords<AV extends AuthVerifier>(
|
2273
|
+
cfg: ConfigOf<
|
2274
|
+
AV,
|
2275
|
+
ToolsOzoneModerationGetRecords.Handler<ExtractAuth<AV>>,
|
2276
|
+
ToolsOzoneModerationGetRecords.HandlerReqCtx<ExtractAuth<AV>>
|
2277
|
+
>,
|
2278
|
+
) {
|
2279
|
+
const nsid = 'tools.ozone.moderation.getRecords' // @ts-ignore
|
2280
|
+
return this._server.xrpc.method(nsid, cfg)
|
2281
|
+
}
|
2282
|
+
|
2265
2283
|
getRepo<AV extends AuthVerifier>(
|
2266
2284
|
cfg: ConfigOf<
|
2267
2285
|
AV,
|
@@ -2273,6 +2291,17 @@ export class ToolsOzoneModerationNS {
|
|
2273
2291
|
return this._server.xrpc.method(nsid, cfg)
|
2274
2292
|
}
|
2275
2293
|
|
2294
|
+
getRepos<AV extends AuthVerifier>(
|
2295
|
+
cfg: ConfigOf<
|
2296
|
+
AV,
|
2297
|
+
ToolsOzoneModerationGetRepos.Handler<ExtractAuth<AV>>,
|
2298
|
+
ToolsOzoneModerationGetRepos.HandlerReqCtx<ExtractAuth<AV>>
|
2299
|
+
>,
|
2300
|
+
) {
|
2301
|
+
const nsid = 'tools.ozone.moderation.getRepos' // @ts-ignore
|
2302
|
+
return this._server.xrpc.method(nsid, cfg)
|
2303
|
+
}
|
2304
|
+
|
2276
2305
|
queryEvents<AV extends AuthVerifier>(
|
2277
2306
|
cfg: ConfigOf<
|
2278
2307
|
AV,
|
@@ -2326,6 +2355,47 @@ export class ToolsOzoneServerNS {
|
|
2326
2355
|
}
|
2327
2356
|
}
|
2328
2357
|
|
2358
|
+
export class ToolsOzoneSignatureNS {
|
2359
|
+
_server: Server
|
2360
|
+
|
2361
|
+
constructor(server: Server) {
|
2362
|
+
this._server = server
|
2363
|
+
}
|
2364
|
+
|
2365
|
+
findCorrelation<AV extends AuthVerifier>(
|
2366
|
+
cfg: ConfigOf<
|
2367
|
+
AV,
|
2368
|
+
ToolsOzoneSignatureFindCorrelation.Handler<ExtractAuth<AV>>,
|
2369
|
+
ToolsOzoneSignatureFindCorrelation.HandlerReqCtx<ExtractAuth<AV>>
|
2370
|
+
>,
|
2371
|
+
) {
|
2372
|
+
const nsid = 'tools.ozone.signature.findCorrelation' // @ts-ignore
|
2373
|
+
return this._server.xrpc.method(nsid, cfg)
|
2374
|
+
}
|
2375
|
+
|
2376
|
+
findRelatedAccounts<AV extends AuthVerifier>(
|
2377
|
+
cfg: ConfigOf<
|
2378
|
+
AV,
|
2379
|
+
ToolsOzoneSignatureFindRelatedAccounts.Handler<ExtractAuth<AV>>,
|
2380
|
+
ToolsOzoneSignatureFindRelatedAccounts.HandlerReqCtx<ExtractAuth<AV>>
|
2381
|
+
>,
|
2382
|
+
) {
|
2383
|
+
const nsid = 'tools.ozone.signature.findRelatedAccounts' // @ts-ignore
|
2384
|
+
return this._server.xrpc.method(nsid, cfg)
|
2385
|
+
}
|
2386
|
+
|
2387
|
+
searchAccounts<AV extends AuthVerifier>(
|
2388
|
+
cfg: ConfigOf<
|
2389
|
+
AV,
|
2390
|
+
ToolsOzoneSignatureSearchAccounts.Handler<ExtractAuth<AV>>,
|
2391
|
+
ToolsOzoneSignatureSearchAccounts.HandlerReqCtx<ExtractAuth<AV>>
|
2392
|
+
>,
|
2393
|
+
) {
|
2394
|
+
const nsid = 'tools.ozone.signature.searchAccounts' // @ts-ignore
|
2395
|
+
return this._server.xrpc.method(nsid, cfg)
|
2396
|
+
}
|
2397
|
+
}
|
2398
|
+
|
2329
2399
|
export class ToolsOzoneTeamNS {
|
2330
2400
|
_server: Server
|
2331
2401
|
|
package/src/lexicon/lexicons.ts
CHANGED
@@ -1686,6 +1686,11 @@ export const schemaDict = {
|
|
1686
1686
|
},
|
1687
1687
|
},
|
1688
1688
|
},
|
1689
|
+
errors: [
|
1690
|
+
{
|
1691
|
+
name: 'RecordNotFound',
|
1692
|
+
},
|
1693
|
+
],
|
1689
1694
|
},
|
1690
1695
|
},
|
1691
1696
|
},
|
@@ -11643,6 +11648,49 @@ export const schemaDict = {
|
|
11643
11648
|
},
|
11644
11649
|
},
|
11645
11650
|
},
|
11651
|
+
ToolsOzoneModerationGetRecords: {
|
11652
|
+
lexicon: 1,
|
11653
|
+
id: 'tools.ozone.moderation.getRecords',
|
11654
|
+
defs: {
|
11655
|
+
main: {
|
11656
|
+
type: 'query',
|
11657
|
+
description: 'Get details about some records.',
|
11658
|
+
parameters: {
|
11659
|
+
type: 'params',
|
11660
|
+
required: ['uris'],
|
11661
|
+
properties: {
|
11662
|
+
uris: {
|
11663
|
+
type: 'array',
|
11664
|
+
maxLength: 100,
|
11665
|
+
items: {
|
11666
|
+
type: 'string',
|
11667
|
+
format: 'at-uri',
|
11668
|
+
},
|
11669
|
+
},
|
11670
|
+
},
|
11671
|
+
},
|
11672
|
+
output: {
|
11673
|
+
encoding: 'application/json',
|
11674
|
+
schema: {
|
11675
|
+
type: 'object',
|
11676
|
+
required: ['records'],
|
11677
|
+
properties: {
|
11678
|
+
records: {
|
11679
|
+
type: 'array',
|
11680
|
+
items: {
|
11681
|
+
type: 'union',
|
11682
|
+
refs: [
|
11683
|
+
'lex:tools.ozone.moderation.defs#recordViewDetail',
|
11684
|
+
'lex:tools.ozone.moderation.defs#recordViewNotFound',
|
11685
|
+
],
|
11686
|
+
},
|
11687
|
+
},
|
11688
|
+
},
|
11689
|
+
},
|
11690
|
+
},
|
11691
|
+
},
|
11692
|
+
},
|
11693
|
+
},
|
11646
11694
|
ToolsOzoneModerationGetRepo: {
|
11647
11695
|
lexicon: 1,
|
11648
11696
|
id: 'tools.ozone.moderation.getRepo',
|
@@ -11675,6 +11723,49 @@ export const schemaDict = {
|
|
11675
11723
|
},
|
11676
11724
|
},
|
11677
11725
|
},
|
11726
|
+
ToolsOzoneModerationGetRepos: {
|
11727
|
+
lexicon: 1,
|
11728
|
+
id: 'tools.ozone.moderation.getRepos',
|
11729
|
+
defs: {
|
11730
|
+
main: {
|
11731
|
+
type: 'query',
|
11732
|
+
description: 'Get details about some repositories.',
|
11733
|
+
parameters: {
|
11734
|
+
type: 'params',
|
11735
|
+
required: ['dids'],
|
11736
|
+
properties: {
|
11737
|
+
dids: {
|
11738
|
+
type: 'array',
|
11739
|
+
maxLength: 100,
|
11740
|
+
items: {
|
11741
|
+
type: 'string',
|
11742
|
+
format: 'did',
|
11743
|
+
},
|
11744
|
+
},
|
11745
|
+
},
|
11746
|
+
},
|
11747
|
+
output: {
|
11748
|
+
encoding: 'application/json',
|
11749
|
+
schema: {
|
11750
|
+
type: 'object',
|
11751
|
+
required: ['repos'],
|
11752
|
+
properties: {
|
11753
|
+
repos: {
|
11754
|
+
type: 'array',
|
11755
|
+
items: {
|
11756
|
+
type: 'union',
|
11757
|
+
refs: [
|
11758
|
+
'lex:tools.ozone.moderation.defs#repoViewDetail',
|
11759
|
+
'lex:tools.ozone.moderation.defs#repoViewNotFound',
|
11760
|
+
],
|
11761
|
+
},
|
11762
|
+
},
|
11763
|
+
},
|
11764
|
+
},
|
11765
|
+
},
|
11766
|
+
},
|
11767
|
+
},
|
11768
|
+
},
|
11678
11769
|
ToolsOzoneModerationQueryEvents: {
|
11679
11770
|
lexicon: 1,
|
11680
11771
|
id: 'tools.ozone.moderation.queryEvents',
|
@@ -12048,6 +12139,181 @@ export const schemaDict = {
|
|
12048
12139
|
},
|
12049
12140
|
},
|
12050
12141
|
},
|
12142
|
+
ToolsOzoneSignatureDefs: {
|
12143
|
+
lexicon: 1,
|
12144
|
+
id: 'tools.ozone.signature.defs',
|
12145
|
+
defs: {
|
12146
|
+
sigDetail: {
|
12147
|
+
type: 'object',
|
12148
|
+
required: ['property', 'value'],
|
12149
|
+
properties: {
|
12150
|
+
property: {
|
12151
|
+
type: 'string',
|
12152
|
+
},
|
12153
|
+
value: {
|
12154
|
+
type: 'string',
|
12155
|
+
},
|
12156
|
+
},
|
12157
|
+
},
|
12158
|
+
},
|
12159
|
+
},
|
12160
|
+
ToolsOzoneSignatureFindCorrelation: {
|
12161
|
+
lexicon: 1,
|
12162
|
+
id: 'tools.ozone.signature.findCorrelation',
|
12163
|
+
defs: {
|
12164
|
+
main: {
|
12165
|
+
type: 'query',
|
12166
|
+
description:
|
12167
|
+
'Find all correlated threat signatures between 2 or more accounts.',
|
12168
|
+
parameters: {
|
12169
|
+
type: 'params',
|
12170
|
+
required: ['dids'],
|
12171
|
+
properties: {
|
12172
|
+
dids: {
|
12173
|
+
type: 'array',
|
12174
|
+
items: {
|
12175
|
+
type: 'string',
|
12176
|
+
format: 'did',
|
12177
|
+
},
|
12178
|
+
},
|
12179
|
+
},
|
12180
|
+
},
|
12181
|
+
output: {
|
12182
|
+
encoding: 'application/json',
|
12183
|
+
schema: {
|
12184
|
+
type: 'object',
|
12185
|
+
required: ['details'],
|
12186
|
+
properties: {
|
12187
|
+
details: {
|
12188
|
+
type: 'array',
|
12189
|
+
items: {
|
12190
|
+
type: 'ref',
|
12191
|
+
ref: 'lex:tools.ozone.signature.defs#sigDetail',
|
12192
|
+
},
|
12193
|
+
},
|
12194
|
+
},
|
12195
|
+
},
|
12196
|
+
},
|
12197
|
+
},
|
12198
|
+
},
|
12199
|
+
},
|
12200
|
+
ToolsOzoneSignatureFindRelatedAccounts: {
|
12201
|
+
lexicon: 1,
|
12202
|
+
id: 'tools.ozone.signature.findRelatedAccounts',
|
12203
|
+
defs: {
|
12204
|
+
main: {
|
12205
|
+
type: 'query',
|
12206
|
+
description:
|
12207
|
+
'Get accounts that share some matching threat signatures with the root account.',
|
12208
|
+
parameters: {
|
12209
|
+
type: 'params',
|
12210
|
+
required: ['did'],
|
12211
|
+
properties: {
|
12212
|
+
did: {
|
12213
|
+
type: 'string',
|
12214
|
+
format: 'did',
|
12215
|
+
},
|
12216
|
+
cursor: {
|
12217
|
+
type: 'string',
|
12218
|
+
},
|
12219
|
+
limit: {
|
12220
|
+
type: 'integer',
|
12221
|
+
minimum: 1,
|
12222
|
+
maximum: 100,
|
12223
|
+
default: 50,
|
12224
|
+
},
|
12225
|
+
},
|
12226
|
+
},
|
12227
|
+
output: {
|
12228
|
+
encoding: 'application/json',
|
12229
|
+
schema: {
|
12230
|
+
type: 'object',
|
12231
|
+
required: ['accounts'],
|
12232
|
+
properties: {
|
12233
|
+
cursor: {
|
12234
|
+
type: 'string',
|
12235
|
+
},
|
12236
|
+
accounts: {
|
12237
|
+
type: 'array',
|
12238
|
+
items: {
|
12239
|
+
type: 'ref',
|
12240
|
+
ref: 'lex:tools.ozone.signature.findRelatedAccounts#relatedAccount',
|
12241
|
+
},
|
12242
|
+
},
|
12243
|
+
},
|
12244
|
+
},
|
12245
|
+
},
|
12246
|
+
},
|
12247
|
+
relatedAccount: {
|
12248
|
+
type: 'object',
|
12249
|
+
required: ['account'],
|
12250
|
+
properties: {
|
12251
|
+
account: {
|
12252
|
+
type: 'ref',
|
12253
|
+
ref: 'lex:com.atproto.admin.defs#accountView',
|
12254
|
+
},
|
12255
|
+
similarities: {
|
12256
|
+
type: 'array',
|
12257
|
+
items: {
|
12258
|
+
type: 'ref',
|
12259
|
+
ref: 'lex:tools.ozone.signature.defs#sigDetail',
|
12260
|
+
},
|
12261
|
+
},
|
12262
|
+
},
|
12263
|
+
},
|
12264
|
+
},
|
12265
|
+
},
|
12266
|
+
ToolsOzoneSignatureSearchAccounts: {
|
12267
|
+
lexicon: 1,
|
12268
|
+
id: 'tools.ozone.signature.searchAccounts',
|
12269
|
+
defs: {
|
12270
|
+
main: {
|
12271
|
+
type: 'query',
|
12272
|
+
description:
|
12273
|
+
'Search for accounts that match one or more threat signature values.',
|
12274
|
+
parameters: {
|
12275
|
+
type: 'params',
|
12276
|
+
required: ['values'],
|
12277
|
+
properties: {
|
12278
|
+
values: {
|
12279
|
+
type: 'array',
|
12280
|
+
items: {
|
12281
|
+
type: 'string',
|
12282
|
+
},
|
12283
|
+
},
|
12284
|
+
cursor: {
|
12285
|
+
type: 'string',
|
12286
|
+
},
|
12287
|
+
limit: {
|
12288
|
+
type: 'integer',
|
12289
|
+
minimum: 1,
|
12290
|
+
maximum: 100,
|
12291
|
+
default: 50,
|
12292
|
+
},
|
12293
|
+
},
|
12294
|
+
},
|
12295
|
+
output: {
|
12296
|
+
encoding: 'application/json',
|
12297
|
+
schema: {
|
12298
|
+
type: 'object',
|
12299
|
+
required: ['accounts'],
|
12300
|
+
properties: {
|
12301
|
+
cursor: {
|
12302
|
+
type: 'string',
|
12303
|
+
},
|
12304
|
+
accounts: {
|
12305
|
+
type: 'array',
|
12306
|
+
items: {
|
12307
|
+
type: 'ref',
|
12308
|
+
ref: 'lex:com.atproto.admin.defs#accountView',
|
12309
|
+
},
|
12310
|
+
},
|
12311
|
+
},
|
12312
|
+
},
|
12313
|
+
},
|
12314
|
+
},
|
12315
|
+
},
|
12316
|
+
},
|
12051
12317
|
ToolsOzoneTeamAddMember: {
|
12052
12318
|
lexicon: 1,
|
12053
12319
|
id: 'tools.ozone.team.addMember',
|
@@ -12491,11 +12757,18 @@ export const ids = {
|
|
12491
12757
|
ToolsOzoneModerationEmitEvent: 'tools.ozone.moderation.emitEvent',
|
12492
12758
|
ToolsOzoneModerationGetEvent: 'tools.ozone.moderation.getEvent',
|
12493
12759
|
ToolsOzoneModerationGetRecord: 'tools.ozone.moderation.getRecord',
|
12760
|
+
ToolsOzoneModerationGetRecords: 'tools.ozone.moderation.getRecords',
|
12494
12761
|
ToolsOzoneModerationGetRepo: 'tools.ozone.moderation.getRepo',
|
12762
|
+
ToolsOzoneModerationGetRepos: 'tools.ozone.moderation.getRepos',
|
12495
12763
|
ToolsOzoneModerationQueryEvents: 'tools.ozone.moderation.queryEvents',
|
12496
12764
|
ToolsOzoneModerationQueryStatuses: 'tools.ozone.moderation.queryStatuses',
|
12497
12765
|
ToolsOzoneModerationSearchRepos: 'tools.ozone.moderation.searchRepos',
|
12498
12766
|
ToolsOzoneServerGetConfig: 'tools.ozone.server.getConfig',
|
12767
|
+
ToolsOzoneSignatureDefs: 'tools.ozone.signature.defs',
|
12768
|
+
ToolsOzoneSignatureFindCorrelation: 'tools.ozone.signature.findCorrelation',
|
12769
|
+
ToolsOzoneSignatureFindRelatedAccounts:
|
12770
|
+
'tools.ozone.signature.findRelatedAccounts',
|
12771
|
+
ToolsOzoneSignatureSearchAccounts: 'tools.ozone.signature.searchAccounts',
|
12499
12772
|
ToolsOzoneTeamAddMember: 'tools.ozone.team.addMember',
|
12500
12773
|
ToolsOzoneTeamDefs: 'tools.ozone.team.defs',
|
12501
12774
|
ToolsOzoneTeamDeleteMember: 'tools.ozone.team.deleteMember',
|
@@ -0,0 +1,50 @@
|
|
1
|
+
/**
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
3
|
+
*/
|
4
|
+
import express from 'express'
|
5
|
+
import { ValidationResult, BlobRef } from '@atproto/lexicon'
|
6
|
+
import { lexicons } from '../../../../lexicons'
|
7
|
+
import { isObj, hasProp } from '../../../../util'
|
8
|
+
import { CID } from 'multiformats/cid'
|
9
|
+
import { HandlerAuth, HandlerPipeThrough } from '@atproto/xrpc-server'
|
10
|
+
import * as ToolsOzoneModerationDefs from './defs'
|
11
|
+
|
12
|
+
export interface QueryParams {
|
13
|
+
uris: string[]
|
14
|
+
}
|
15
|
+
|
16
|
+
export type InputSchema = undefined
|
17
|
+
|
18
|
+
export interface OutputSchema {
|
19
|
+
records: (
|
20
|
+
| ToolsOzoneModerationDefs.RecordViewDetail
|
21
|
+
| ToolsOzoneModerationDefs.RecordViewNotFound
|
22
|
+
| { $type: string; [k: string]: unknown }
|
23
|
+
)[]
|
24
|
+
[k: string]: unknown
|
25
|
+
}
|
26
|
+
|
27
|
+
export type HandlerInput = undefined
|
28
|
+
|
29
|
+
export interface HandlerSuccess {
|
30
|
+
encoding: 'application/json'
|
31
|
+
body: OutputSchema
|
32
|
+
headers?: { [key: string]: string }
|
33
|
+
}
|
34
|
+
|
35
|
+
export interface HandlerError {
|
36
|
+
status: number
|
37
|
+
message?: string
|
38
|
+
}
|
39
|
+
|
40
|
+
export type HandlerOutput = HandlerError | HandlerSuccess | HandlerPipeThrough
|
41
|
+
export type HandlerReqCtx<HA extends HandlerAuth = never> = {
|
42
|
+
auth: HA
|
43
|
+
params: QueryParams
|
44
|
+
input: HandlerInput
|
45
|
+
req: express.Request
|
46
|
+
res: express.Response
|
47
|
+
}
|
48
|
+
export type Handler<HA extends HandlerAuth = never> = (
|
49
|
+
ctx: HandlerReqCtx<HA>,
|
50
|
+
) => Promise<HandlerOutput> | HandlerOutput
|
@@ -0,0 +1,50 @@
|
|
1
|
+
/**
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
3
|
+
*/
|
4
|
+
import express from 'express'
|
5
|
+
import { ValidationResult, BlobRef } from '@atproto/lexicon'
|
6
|
+
import { lexicons } from '../../../../lexicons'
|
7
|
+
import { isObj, hasProp } from '../../../../util'
|
8
|
+
import { CID } from 'multiformats/cid'
|
9
|
+
import { HandlerAuth, HandlerPipeThrough } from '@atproto/xrpc-server'
|
10
|
+
import * as ToolsOzoneModerationDefs from './defs'
|
11
|
+
|
12
|
+
export interface QueryParams {
|
13
|
+
dids: string[]
|
14
|
+
}
|
15
|
+
|
16
|
+
export type InputSchema = undefined
|
17
|
+
|
18
|
+
export interface OutputSchema {
|
19
|
+
repos: (
|
20
|
+
| ToolsOzoneModerationDefs.RepoViewDetail
|
21
|
+
| ToolsOzoneModerationDefs.RepoViewNotFound
|
22
|
+
| { $type: string; [k: string]: unknown }
|
23
|
+
)[]
|
24
|
+
[k: string]: unknown
|
25
|
+
}
|
26
|
+
|
27
|
+
export type HandlerInput = undefined
|
28
|
+
|
29
|
+
export interface HandlerSuccess {
|
30
|
+
encoding: 'application/json'
|
31
|
+
body: OutputSchema
|
32
|
+
headers?: { [key: string]: string }
|
33
|
+
}
|
34
|
+
|
35
|
+
export interface HandlerError {
|
36
|
+
status: number
|
37
|
+
message?: string
|
38
|
+
}
|
39
|
+
|
40
|
+
export type HandlerOutput = HandlerError | HandlerSuccess | HandlerPipeThrough
|
41
|
+
export type HandlerReqCtx<HA extends HandlerAuth = never> = {
|
42
|
+
auth: HA
|
43
|
+
params: QueryParams
|
44
|
+
input: HandlerInput
|
45
|
+
req: express.Request
|
46
|
+
res: express.Response
|
47
|
+
}
|
48
|
+
export type Handler<HA extends HandlerAuth = never> = (
|
49
|
+
ctx: HandlerReqCtx<HA>,
|
50
|
+
) => Promise<HandlerOutput> | HandlerOutput
|
@@ -0,0 +1,25 @@
|
|
1
|
+
/**
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
3
|
+
*/
|
4
|
+
import { ValidationResult, BlobRef } from '@atproto/lexicon'
|
5
|
+
import { lexicons } from '../../../../lexicons'
|
6
|
+
import { isObj, hasProp } from '../../../../util'
|
7
|
+
import { CID } from 'multiformats/cid'
|
8
|
+
|
9
|
+
export interface SigDetail {
|
10
|
+
property: string
|
11
|
+
value: string
|
12
|
+
[k: string]: unknown
|
13
|
+
}
|
14
|
+
|
15
|
+
export function isSigDetail(v: unknown): v is SigDetail {
|
16
|
+
return (
|
17
|
+
isObj(v) &&
|
18
|
+
hasProp(v, '$type') &&
|
19
|
+
v.$type === 'tools.ozone.signature.defs#sigDetail'
|
20
|
+
)
|
21
|
+
}
|
22
|
+
|
23
|
+
export function validateSigDetail(v: unknown): ValidationResult {
|
24
|
+
return lexicons.validate('tools.ozone.signature.defs#sigDetail', v)
|
25
|
+
}
|
@@ -0,0 +1,46 @@
|
|
1
|
+
/**
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
3
|
+
*/
|
4
|
+
import express from 'express'
|
5
|
+
import { ValidationResult, BlobRef } from '@atproto/lexicon'
|
6
|
+
import { lexicons } from '../../../../lexicons'
|
7
|
+
import { isObj, hasProp } from '../../../../util'
|
8
|
+
import { CID } from 'multiformats/cid'
|
9
|
+
import { HandlerAuth, HandlerPipeThrough } from '@atproto/xrpc-server'
|
10
|
+
import * as ToolsOzoneSignatureDefs from './defs'
|
11
|
+
|
12
|
+
export interface QueryParams {
|
13
|
+
dids: string[]
|
14
|
+
}
|
15
|
+
|
16
|
+
export type InputSchema = undefined
|
17
|
+
|
18
|
+
export interface OutputSchema {
|
19
|
+
details: ToolsOzoneSignatureDefs.SigDetail[]
|
20
|
+
[k: string]: unknown
|
21
|
+
}
|
22
|
+
|
23
|
+
export type HandlerInput = undefined
|
24
|
+
|
25
|
+
export interface HandlerSuccess {
|
26
|
+
encoding: 'application/json'
|
27
|
+
body: OutputSchema
|
28
|
+
headers?: { [key: string]: string }
|
29
|
+
}
|
30
|
+
|
31
|
+
export interface HandlerError {
|
32
|
+
status: number
|
33
|
+
message?: string
|
34
|
+
}
|
35
|
+
|
36
|
+
export type HandlerOutput = HandlerError | HandlerSuccess | HandlerPipeThrough
|
37
|
+
export type HandlerReqCtx<HA extends HandlerAuth = never> = {
|
38
|
+
auth: HA
|
39
|
+
params: QueryParams
|
40
|
+
input: HandlerInput
|
41
|
+
req: express.Request
|
42
|
+
res: express.Response
|
43
|
+
}
|
44
|
+
export type Handler<HA extends HandlerAuth = never> = (
|
45
|
+
ctx: HandlerReqCtx<HA>,
|
46
|
+
) => Promise<HandlerOutput> | HandlerOutput
|
@@ -0,0 +1,71 @@
|
|
1
|
+
/**
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
3
|
+
*/
|
4
|
+
import express from 'express'
|
5
|
+
import { ValidationResult, BlobRef } from '@atproto/lexicon'
|
6
|
+
import { lexicons } from '../../../../lexicons'
|
7
|
+
import { isObj, hasProp } from '../../../../util'
|
8
|
+
import { CID } from 'multiformats/cid'
|
9
|
+
import { HandlerAuth, HandlerPipeThrough } from '@atproto/xrpc-server'
|
10
|
+
import * as ComAtprotoAdminDefs from '../../../com/atproto/admin/defs'
|
11
|
+
import * as ToolsOzoneSignatureDefs from './defs'
|
12
|
+
|
13
|
+
export interface QueryParams {
|
14
|
+
did: string
|
15
|
+
cursor?: string
|
16
|
+
limit: number
|
17
|
+
}
|
18
|
+
|
19
|
+
export type InputSchema = undefined
|
20
|
+
|
21
|
+
export interface OutputSchema {
|
22
|
+
cursor?: string
|
23
|
+
accounts: RelatedAccount[]
|
24
|
+
[k: string]: unknown
|
25
|
+
}
|
26
|
+
|
27
|
+
export type HandlerInput = undefined
|
28
|
+
|
29
|
+
export interface HandlerSuccess {
|
30
|
+
encoding: 'application/json'
|
31
|
+
body: OutputSchema
|
32
|
+
headers?: { [key: string]: string }
|
33
|
+
}
|
34
|
+
|
35
|
+
export interface HandlerError {
|
36
|
+
status: number
|
37
|
+
message?: string
|
38
|
+
}
|
39
|
+
|
40
|
+
export type HandlerOutput = HandlerError | HandlerSuccess | HandlerPipeThrough
|
41
|
+
export type HandlerReqCtx<HA extends HandlerAuth = never> = {
|
42
|
+
auth: HA
|
43
|
+
params: QueryParams
|
44
|
+
input: HandlerInput
|
45
|
+
req: express.Request
|
46
|
+
res: express.Response
|
47
|
+
}
|
48
|
+
export type Handler<HA extends HandlerAuth = never> = (
|
49
|
+
ctx: HandlerReqCtx<HA>,
|
50
|
+
) => Promise<HandlerOutput> | HandlerOutput
|
51
|
+
|
52
|
+
export interface RelatedAccount {
|
53
|
+
account: ComAtprotoAdminDefs.AccountView
|
54
|
+
similarities?: ToolsOzoneSignatureDefs.SigDetail[]
|
55
|
+
[k: string]: unknown
|
56
|
+
}
|
57
|
+
|
58
|
+
export function isRelatedAccount(v: unknown): v is RelatedAccount {
|
59
|
+
return (
|
60
|
+
isObj(v) &&
|
61
|
+
hasProp(v, '$type') &&
|
62
|
+
v.$type === 'tools.ozone.signature.findRelatedAccounts#relatedAccount'
|
63
|
+
)
|
64
|
+
}
|
65
|
+
|
66
|
+
export function validateRelatedAccount(v: unknown): ValidationResult {
|
67
|
+
return lexicons.validate(
|
68
|
+
'tools.ozone.signature.findRelatedAccounts#relatedAccount',
|
69
|
+
v,
|
70
|
+
)
|
71
|
+
}
|