@atproto/pds 0.4.199 → 0.4.201
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 +25 -0
- package/dist/api/com/atproto/server/createSession.d.ts.map +1 -1
- package/dist/api/com/atproto/server/createSession.js +2 -2
- package/dist/api/com/atproto/server/createSession.js.map +1 -1
- package/dist/api/com/atproto/server/getSession.js +2 -2
- package/dist/api/com/atproto/server/getSession.js.map +1 -1
- package/dist/api/com/atproto/server/refreshSession.d.ts.map +1 -1
- package/dist/api/com/atproto/server/refreshSession.js +4 -2
- package/dist/api/com/atproto/server/refreshSession.js.map +1 -1
- package/dist/lexicon/lexicons.d.ts +144 -54
- package/dist/lexicon/lexicons.d.ts.map +1 -1
- package/dist/lexicon/lexicons.js +94 -26
- package/dist/lexicon/lexicons.js.map +1 -1
- package/dist/lexicon/types/app/bsky/contact/dismissMatch.d.ts +1 -1
- package/dist/lexicon/types/app/bsky/contact/dismissMatch.d.ts.map +1 -1
- package/dist/lexicon/types/app/bsky/contact/dismissMatch.js.map +1 -1
- package/dist/lexicon/types/app/bsky/contact/getMatches.d.ts +1 -1
- package/dist/lexicon/types/app/bsky/contact/getMatches.d.ts.map +1 -1
- package/dist/lexicon/types/app/bsky/contact/getMatches.js.map +1 -1
- package/dist/lexicon/types/app/bsky/contact/getSyncStatus.d.ts +1 -1
- package/dist/lexicon/types/app/bsky/contact/getSyncStatus.d.ts.map +1 -1
- package/dist/lexicon/types/app/bsky/contact/getSyncStatus.js.map +1 -1
- package/dist/lexicon/types/app/bsky/contact/importContacts.d.ts +1 -1
- package/dist/lexicon/types/app/bsky/contact/importContacts.d.ts.map +1 -1
- package/dist/lexicon/types/app/bsky/contact/importContacts.js.map +1 -1
- package/dist/lexicon/types/app/bsky/contact/removeData.d.ts +1 -1
- package/dist/lexicon/types/app/bsky/contact/removeData.d.ts.map +1 -1
- package/dist/lexicon/types/app/bsky/contact/removeData.js.map +1 -1
- package/dist/lexicon/types/app/bsky/contact/startPhoneVerification.d.ts +1 -1
- package/dist/lexicon/types/app/bsky/contact/startPhoneVerification.d.ts.map +1 -1
- package/dist/lexicon/types/app/bsky/contact/startPhoneVerification.js.map +1 -1
- package/dist/lexicon/types/app/bsky/contact/verifyPhone.d.ts +1 -1
- package/dist/lexicon/types/app/bsky/contact/verifyPhone.d.ts.map +1 -1
- package/dist/lexicon/types/app/bsky/contact/verifyPhone.js.map +1 -1
- package/dist/lexicon/types/app/bsky/notification/listNotifications.d.ts +1 -1
- package/dist/lexicon/types/app/bsky/notification/listNotifications.d.ts.map +1 -1
- package/dist/lexicon/types/app/bsky/notification/listNotifications.js.map +1 -1
- package/dist/lexicon/types/com/atproto/server/deleteSession.d.ts +1 -0
- package/dist/lexicon/types/com/atproto/server/deleteSession.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/server/deleteSession.js.map +1 -1
- package/dist/lexicon/types/com/atproto/server/getSession.d.ts +3 -3
- package/dist/lexicon/types/com/atproto/server/getSession.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/server/getSession.js.map +1 -1
- package/dist/lexicon/types/com/atproto/server/refreshSession.d.ts +4 -1
- package/dist/lexicon/types/com/atproto/server/refreshSession.d.ts.map +1 -1
- package/dist/lexicon/types/com/atproto/server/refreshSession.js.map +1 -1
- package/package.json +15 -15
- package/src/api/com/atproto/server/createSession.ts +3 -2
- package/src/api/com/atproto/server/getSession.ts +2 -2
- package/src/api/com/atproto/server/refreshSession.ts +5 -2
- package/src/lexicon/lexicons.ts +95 -26
- package/src/lexicon/types/app/bsky/contact/dismissMatch.ts +1 -1
- package/src/lexicon/types/app/bsky/contact/getMatches.ts +1 -1
- package/src/lexicon/types/app/bsky/contact/getSyncStatus.ts +1 -1
- package/src/lexicon/types/app/bsky/contact/importContacts.ts +6 -1
- package/src/lexicon/types/app/bsky/contact/removeData.ts +1 -1
- package/src/lexicon/types/app/bsky/contact/startPhoneVerification.ts +1 -1
- package/src/lexicon/types/app/bsky/contact/verifyPhone.ts +6 -1
- package/src/lexicon/types/app/bsky/notification/listNotifications.ts +1 -0
- package/src/lexicon/types/com/atproto/server/deleteSession.ts +1 -0
- package/src/lexicon/types/com/atproto/server/getSession.ts +1 -1
- package/src/lexicon/types/com/atproto/server/refreshSession.ts +4 -1
- package/tests/_puppeteer.ts +87 -0
- package/tests/oauth.test.ts +54 -94
- package/tsconfig.tests.tsbuildinfo +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,30 @@
|
|
|
1
1
|
# @atproto/pds
|
|
2
2
|
|
|
3
|
+
## 0.4.201
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [[`9af7a2d`](https://github.com/bluesky-social/atproto/commit/9af7a2d12240e91248610ce4fe7d93387733c59c), [`9af7a2d`](https://github.com/bluesky-social/atproto/commit/9af7a2d12240e91248610ce4fe7d93387733c59c)]:
|
|
8
|
+
- @atproto/lex-data@0.0.5
|
|
9
|
+
- @atproto/common@0.5.5
|
|
10
|
+
- @atproto/lex-cbor@0.0.5
|
|
11
|
+
- @atproto/xrpc-server@0.10.6
|
|
12
|
+
- @atproto/oauth-provider@0.15.1
|
|
13
|
+
|
|
14
|
+
## 0.4.200
|
|
15
|
+
|
|
16
|
+
### Patch Changes
|
|
17
|
+
|
|
18
|
+
- [#4470](https://github.com/bluesky-social/atproto/pull/4470) [`10cf1c1`](https://github.com/bluesky-social/atproto/commit/10cf1c10188596724b0c38a5af507d95a382a164) Thanks [@matthieusieben](https://github.com/matthieusieben)! - `refreshSession` now returns `email` and `emailConfirmed` fields (same as `createSession` and `getSession`)
|
|
19
|
+
|
|
20
|
+
- Updated dependencies [[`e6b6107`](https://github.com/bluesky-social/atproto/commit/e6b6107e028fee964972274b71f5da1329a7bece), [`e6b6107`](https://github.com/bluesky-social/atproto/commit/e6b6107e028fee964972274b71f5da1329a7bece), [`10cf1c1`](https://github.com/bluesky-social/atproto/commit/10cf1c10188596724b0c38a5af507d95a382a164), [`e6b6107`](https://github.com/bluesky-social/atproto/commit/e6b6107e028fee964972274b71f5da1329a7bece), [`10cf1c1`](https://github.com/bluesky-social/atproto/commit/10cf1c10188596724b0c38a5af507d95a382a164), [`e6b6107`](https://github.com/bluesky-social/atproto/commit/e6b6107e028fee964972274b71f5da1329a7bece), [`e6b6107`](https://github.com/bluesky-social/atproto/commit/e6b6107e028fee964972274b71f5da1329a7bece), [`e6b6107`](https://github.com/bluesky-social/atproto/commit/e6b6107e028fee964972274b71f5da1329a7bece), [`5d8e7a6`](https://github.com/bluesky-social/atproto/commit/5d8e7a6588fc9e57e15d83d47bb45103205e3e41), [`5d8e7a6`](https://github.com/bluesky-social/atproto/commit/5d8e7a6588fc9e57e15d83d47bb45103205e3e41)]:
|
|
21
|
+
- @atproto/lex-data@0.0.4
|
|
22
|
+
- @atproto/api@0.18.9
|
|
23
|
+
- @atproto/lex-cbor@0.0.4
|
|
24
|
+
- @atproto/oauth-provider@0.15.0
|
|
25
|
+
- @atproto/common@0.5.4
|
|
26
|
+
- @atproto/xrpc-server@0.10.5
|
|
27
|
+
|
|
3
28
|
## 0.4.199
|
|
4
29
|
|
|
5
30
|
### Patch Changes
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"createSession.d.ts","sourceRoot":"","sources":["../../../../../src/api/com/atproto/server/createSession.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAA;AAChD,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAA;AAI5C,MAAM,CAAC,OAAO,WAAW,MAAM,EAAE,MAAM,EAAE,GAAG,EAAE,UAAU,
|
|
1
|
+
{"version":3,"file":"createSession.d.ts","sourceRoot":"","sources":["../../../../../src/api/com/atproto/server/createSession.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAA;AAChD,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAA;AAI5C,MAAM,CAAC,OAAO,WAAW,MAAM,EAAE,MAAM,EAAE,GAAG,EAAE,UAAU,QAgEvD"}
|
|
@@ -41,13 +41,13 @@ function default_1(server, ctx) {
|
|
|
41
41
|
return {
|
|
42
42
|
encoding: 'application/json',
|
|
43
43
|
body: {
|
|
44
|
+
accessJwt,
|
|
45
|
+
refreshJwt,
|
|
44
46
|
did: user.did,
|
|
45
47
|
didDoc,
|
|
46
48
|
handle: user.handle ?? syntax_1.INVALID_HANDLE,
|
|
47
49
|
email: user.email ?? undefined,
|
|
48
50
|
emailConfirmed: !!user.emailConfirmedAt,
|
|
49
|
-
accessJwt,
|
|
50
|
-
refreshJwt,
|
|
51
51
|
active,
|
|
52
52
|
status,
|
|
53
53
|
},
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"createSession.js","sourceRoot":"","sources":["../../../../../src/api/com/atproto/server/createSession.ts"],"names":[],"mappings":";;AAUA,
|
|
1
|
+
{"version":3,"file":"createSession.js","sourceRoot":"","sources":["../../../../../src/api/com/atproto/server/createSession.ts"],"names":[],"mappings":";;AAUA,4BAgEC;AA1ED,4CAA6C;AAC7C,4CAAgD;AAChD,sDAAwD;AACxD,iFAAiF;AACjF,uEAAoF;AAGpF,0CAA+C;AAC/C,iCAAyC;AAEzC,mBAAyB,MAAc,EAAE,GAAe;IACtD,MAAM,CAAC,GAAG,CAAC,OAAO,CAAC,MAAM,CAAC,aAAa,CAAC;QACtC,SAAS,EAAE;YACT;gBACE,UAAU,EAAE,YAAG;gBACf,MAAM,EAAE,GAAG;gBACX,OAAO,EAAE,CAAC,EAAE,KAAK,EAAE,GAAG,EAAE,EAAE,EAAE,CAAC,GAAG,KAAK,CAAC,IAAI,CAAC,UAAU,IAAI,GAAG,CAAC,EAAE,EAAE;aAClE;YACD;gBACE,UAAU,EAAE,CAAC,GAAG,eAAM;gBACtB,MAAM,EAAE,EAAE;gBACV,OAAO,EAAE,CAAC,EAAE,KAAK,EAAE,GAAG,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,EAAE,kBAAkB;gBAC5B,IAAI,EAAE;oBACJ,SAAS;oBACT,UAAU;oBAEV,GAAG,EAAE,IAAI,CAAC,GAAG;oBACb,MAAM;oBACN,MAAM,EAAE,IAAI,CAAC,MAAM,IAAI,uBAAc;oBACrC,KAAK,EAAE,IAAI,CAAC,KAAK,IAAI,SAAS;oBAC9B,cAAc,EAAE,CAAC,CAAC,IAAI,CAAC,gBAAgB;oBACvC,MAAM;oBACN,MAAM;iBACP;aACF,CAAA;QACH,CAAC;KACF,CAAC,CAAA;AACJ,CAAC","sourcesContent":["import { DAY, MINUTE } from '@atproto/common'\nimport { INVALID_HANDLE } from '@atproto/syntax'\nimport { AuthRequiredError } from '@atproto/xrpc-server'\nimport { formatAccountStatus } from '../../../../account-manager/account-manager'\nimport { OLD_PASSWORD_MAX_LENGTH } from '../../../../account-manager/helpers/scrypt'\nimport { AppContext } from '../../../../context'\nimport { Server } from '../../../../lexicon'\nimport { resultPassthru } from '../../../proxy'\nimport { didDocForSession } from './util'\n\nexport default function (server: Server, ctx: AppContext) {\n server.com.atproto.server.createSession({\n rateLimit: [\n {\n durationMs: DAY,\n points: 300,\n calcKey: ({ input, req }) => `${input.body.identifier}-${req.ip}`,\n },\n {\n durationMs: 5 * MINUTE,\n points: 30,\n calcKey: ({ input, req }) => `${input.body.identifier}-${req.ip}`,\n },\n ],\n handler: async ({ input, req }) => {\n if (ctx.entrywayAgent) {\n return resultPassthru(\n await ctx.entrywayAgent.com.atproto.server.createSession(\n input.body,\n ctx.entrywayPassthruHeaders(req),\n ),\n )\n }\n\n if (input.body.password.length > OLD_PASSWORD_MAX_LENGTH) {\n throw new AuthRequiredError(\n 'Password too long. Consider resetting your password.',\n )\n }\n\n const { user, isSoftDeleted, appPassword } =\n await ctx.accountManager.login(input.body)\n\n if (!input.body.allowTakendown && isSoftDeleted) {\n throw new AuthRequiredError(\n 'Account has been taken down',\n 'AccountTakedown',\n )\n }\n\n const [{ accessJwt, refreshJwt }, didDoc] = await Promise.all([\n ctx.accountManager.createSession(user.did, appPassword, isSoftDeleted),\n didDocForSession(ctx, user.did),\n ])\n\n const { status, active } = formatAccountStatus(user)\n\n return {\n encoding: 'application/json',\n body: {\n accessJwt,\n refreshJwt,\n\n did: user.did,\n didDoc,\n handle: user.handle ?? INVALID_HANDLE,\n email: user.email ?? undefined,\n emailConfirmed: !!user.emailConfirmedAt,\n active,\n status,\n },\n }\n },\n })\n}\n"]}
|
|
@@ -35,10 +35,10 @@ function default_1(server, ctx) {
|
|
|
35
35
|
return {
|
|
36
36
|
encoding: 'application/json',
|
|
37
37
|
body: output(auth, {
|
|
38
|
-
handle: user.handle ?? syntax_1.INVALID_HANDLE,
|
|
39
38
|
did: user.did,
|
|
40
|
-
email: user.email ?? undefined,
|
|
41
39
|
didDoc,
|
|
40
|
+
handle: user.handle ?? syntax_1.INVALID_HANDLE,
|
|
41
|
+
email: user.email ?? undefined,
|
|
42
42
|
emailConfirmed: !!user.emailConfirmedAt,
|
|
43
43
|
active,
|
|
44
44
|
status,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getSession.js","sourceRoot":"","sources":["../../../../../src/api/com/atproto/server/getSession.ts"],"names":[],"mappings":";;AAUA,4BAsDC;AA/DD,4CAAgD;AAChD,sDAA0D;AAC1D,iFAAiF;AAEjF,uDAAkD;AAGlD,iCAAyC;AAEzC,mBAAyB,MAAc,EAAE,GAAe;IACtD,MAAM,CAAC,GAAG,CAAC,OAAO,CAAC,MAAM,CAAC,UAAU,CAAC;QACnC,IAAI,EAAE,GAAG,CAAC,YAAY,CAAC,aAAa,CAAC;YACnC,UAAU,EAAE,CAAC,sBAAS,CAAC,YAAY,CAAC;YACpC,SAAS,EAAE,GAAG,EAAE;gBACd,4DAA4D;YAC9D,CAAC;SACF,CAAC;QACF,OAAO,EAAE,KAAK,EAAE,EAAE,IAAI,EAAE,GAAG,EAAE,EAAE,EAAE;YAC/B,IAAI,GAAG,CAAC,aAAa,EAAE,CAAC;gBACtB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,EAAE,kBAAkB;gBAC5B,IAAI,EAAE,MAAM,CAAC,IAAI,EAAE;oBACjB,GAAG,EAAE,IAAI,CAAC,GAAG;oBACb,MAAM;oBACN,MAAM,EAAE,IAAI,CAAC,MAAM,IAAI,uBAAc;oBACrC,KAAK,EAAE,IAAI,CAAC,KAAK,IAAI,SAAS;oBAC9B,cAAc,EAAE,CAAC,CAAC,IAAI,CAAC,gBAAgB;oBACvC,MAAM;oBACN,MAAM;iBACP,CAAC;aACH,CAAA;QACH,CAAC;KACF,CAAC,CAAA;AACJ,CAAC;AAED,SAAS,MAAM,CACb,EAAE,WAAW,EAA8B,EAC3C,IAA6C;IAE7C,IACE,WAAW,CAAC,IAAI,KAAK,OAAO;QAC5B,CAAC,WAAW,CAAC,WAAW,CAAC,aAAa,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC,EACzE,CAAC;QACD,MAAM,EAAE,KAAK,EAAE,eAAe,EAAE,cAAc,EAAE,GAAG,IAAI,EAAE,GAAG,IAAI,CAAA;QAChE,OAAO,IAAI,CAAA;IACb,CAAC;IAED,OAAO,IAAI,CAAA;AACb,CAAC","sourcesContent":["import { ComAtprotoServerGetSession } from '@atproto/api'\nimport { INVALID_HANDLE } from '@atproto/syntax'\nimport { InvalidRequestError } from '@atproto/xrpc-server'\nimport { formatAccountStatus } from '../../../../account-manager/account-manager'\nimport { AccessOutput, OAuthOutput } from '../../../../auth-output'\nimport { AuthScope } from '../../../../auth-scope'\nimport { AppContext } from '../../../../context'\nimport { Server } from '../../../../lexicon'\nimport { didDocForSession } from './util'\n\nexport default function (server: Server, ctx: AppContext) {\n server.com.atproto.server.getSession({\n auth: ctx.authVerifier.authorization({\n additional: [AuthScope.SignupQueued],\n authorize: () => {\n // Always allowed. \"email\" access is checked in the handler.\n },\n }),\n handler: async ({ auth, req }) => {\n if (ctx.entrywayAgent) {\n const headers = await ctx.entrywayAuthHeaders(\n req,\n auth.credentials.did,\n 'com.atproto.server.getSession',\n )\n\n const res = await ctx.entrywayAgent.com.atproto.server.getSession(\n undefined,\n headers,\n )\n\n return {\n encoding: 'application/json',\n body: output(auth, res.data),\n }\n }\n\n const did = auth.credentials.did\n const [user, didDoc] = await Promise.all([\n ctx.accountManager.getAccount(did, { includeDeactivated: true }),\n didDocForSession(ctx, did),\n ])\n if (!user) {\n throw new InvalidRequestError(\n `Could not find user info for account: ${did}`,\n )\n }\n\n const { status, active } = formatAccountStatus(user)\n\n return {\n encoding: 'application/json',\n body: output(auth, {\n did: user.did,\n didDoc,\n handle: user.handle ?? INVALID_HANDLE,\n email: user.email ?? undefined,\n emailConfirmed: !!user.emailConfirmedAt,\n active,\n status,\n }),\n }\n },\n })\n}\n\nfunction output(\n { credentials }: OAuthOutput | AccessOutput,\n data: ComAtprotoServerGetSession.OutputSchema,\n): ComAtprotoServerGetSession.OutputSchema {\n if (\n credentials.type === 'oauth' &&\n !credentials.permissions.allowsAccount({ attr: 'email', action: 'read' })\n ) {\n const { email, emailAuthFactor, emailConfirmed, ...rest } = data\n return rest\n }\n\n return data\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"refreshSession.d.ts","sourceRoot":"","sources":["../../../../../src/api/com/atproto/server/refreshSession.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAA;AAEhD,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAA;AAI5C,MAAM,CAAC,OAAO,WAAW,MAAM,EAAE,MAAM,EAAE,GAAG,EAAE,UAAU,
|
|
1
|
+
{"version":3,"file":"refreshSession.d.ts","sourceRoot":"","sources":["../../../../../src/api/com/atproto/server/refreshSession.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAA;AAEhD,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAA;AAI5C,MAAM,CAAC,OAAO,WAAW,MAAM,EAAE,MAAM,EAAE,GAAG,EAAE,UAAU,QAyDvD"}
|
|
@@ -36,11 +36,13 @@ function default_1(server, ctx) {
|
|
|
36
36
|
return {
|
|
37
37
|
encoding: 'application/json',
|
|
38
38
|
body: {
|
|
39
|
+
accessJwt: rotated.accessJwt,
|
|
40
|
+
refreshJwt: rotated.refreshJwt,
|
|
39
41
|
did: user.did,
|
|
40
42
|
didDoc,
|
|
41
43
|
handle: user.handle ?? syntax_1.INVALID_HANDLE,
|
|
42
|
-
|
|
43
|
-
|
|
44
|
+
email: user.email ?? undefined,
|
|
45
|
+
emailConfirmed: !!user.emailConfirmedAt,
|
|
44
46
|
active,
|
|
45
47
|
status,
|
|
46
48
|
},
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"refreshSession.js","sourceRoot":"","sources":["../../../../../src/api/com/atproto/server/refreshSession.ts"],"names":[],"mappings":";;AASA,
|
|
1
|
+
{"version":3,"file":"refreshSession.js","sourceRoot":"","sources":["../../../../../src/api/com/atproto/server/refreshSession.ts"],"names":[],"mappings":";;AASA,4BAyDC;AAlED,4CAAgD;AAChD,sDAA6E;AAC7E,iFAAiF;AAEjF,8CAAiD;AAEjD,0CAA+C;AAC/C,iCAAyC;AAEzC,mBAAyB,MAAc,EAAE,GAAe;IACtD,MAAM,CAAC,GAAG,CAAC,OAAO,CAAC,MAAM,CAAC,cAAc,CAAC;QACvC,IAAI,EAAE,GAAG,CAAC,YAAY,CAAC,OAAO,EAAE;QAChC,OAAO,EAAE,KAAK,EAAE,EAAE,IAAI,EAAE,GAAG,EAAE,EAAE,EAAE;YAC/B,MAAM,GAAG,GAAG,IAAI,CAAC,WAAW,CAAC,GAAG,CAAA;YAChC,MAAM,IAAI,GAAG,MAAM,GAAG,CAAC,cAAc,CAAC,UAAU,CAAC,GAAG,EAAE;gBACpD,kBAAkB,EAAE,IAAI;gBACxB,gBAAgB,EAAE,IAAI;aACvB,CAAC,CAAA;YACF,IAAI,CAAC,IAAI,EAAE,CAAC;gBACV,MAAM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BACN,MAAM;iBACP;aACF,CAAA;QACH,CAAC;KACF,CAAC,CAAA;AACJ,CAAC","sourcesContent":["import { INVALID_HANDLE } from '@atproto/syntax'\nimport { AuthRequiredError, InvalidRequestError } from '@atproto/xrpc-server'\nimport { formatAccountStatus } from '../../../../account-manager/account-manager'\nimport { AppContext } from '../../../../context'\nimport { softDeleted } from '../../../../db/util'\nimport { Server } from '../../../../lexicon'\nimport { resultPassthru } from '../../../proxy'\nimport { didDocForSession } from './util'\n\nexport default function (server: Server, ctx: AppContext) {\n server.com.atproto.server.refreshSession({\n auth: ctx.authVerifier.refresh(),\n handler: async ({ auth, req }) => {\n const did = auth.credentials.did\n const user = await ctx.accountManager.getAccount(did, {\n includeDeactivated: true,\n includeTakenDown: true,\n })\n if (!user) {\n throw new InvalidRequestError(\n `Could not find user info for account: ${did}`,\n )\n }\n if (softDeleted(user)) {\n throw new AuthRequiredError(\n 'Account has been taken down',\n 'AccountTakedown',\n )\n }\n\n if (ctx.entrywayAgent) {\n return resultPassthru(\n await ctx.entrywayAgent.com.atproto.server.refreshSession(\n undefined,\n ctx.entrywayPassthruHeaders(req),\n ),\n )\n }\n\n const [didDoc, rotated] = await Promise.all([\n didDocForSession(ctx, user.did),\n ctx.accountManager.rotateRefreshToken(auth.credentials.tokenId),\n ])\n if (rotated === null) {\n throw new InvalidRequestError('Token has been revoked', 'ExpiredToken')\n }\n\n const { status, active } = formatAccountStatus(user)\n\n return {\n encoding: 'application/json',\n body: {\n accessJwt: rotated.accessJwt,\n refreshJwt: rotated.refreshJwt,\n\n did: user.did,\n didDoc,\n handle: user.handle ?? INVALID_HANDLE,\n email: user.email ?? undefined,\n emailConfirmed: !!user.emailConfirmedAt,\n active,\n status,\n },\n }\n },\n })\n}\n"]}
|
|
@@ -1695,7 +1695,7 @@ export declare const schemaDict: {
|
|
|
1695
1695
|
readonly defs: {
|
|
1696
1696
|
readonly main: {
|
|
1697
1697
|
readonly type: "procedure";
|
|
1698
|
-
readonly description: "
|
|
1698
|
+
readonly description: "Removes a match that was found via contact import. It shouldn't appear again if the same contact is re-imported. Requires authentication.";
|
|
1699
1699
|
readonly input: {
|
|
1700
1700
|
readonly encoding: "application/json";
|
|
1701
1701
|
readonly schema: {
|
|
@@ -1718,8 +1718,9 @@ export declare const schemaDict: {
|
|
|
1718
1718
|
};
|
|
1719
1719
|
};
|
|
1720
1720
|
readonly errors: [{
|
|
1721
|
-
readonly name: "
|
|
1722
|
-
|
|
1721
|
+
readonly name: "InvalidDid";
|
|
1722
|
+
}, {
|
|
1723
|
+
readonly name: "InternalError";
|
|
1723
1724
|
}];
|
|
1724
1725
|
};
|
|
1725
1726
|
};
|
|
@@ -1730,7 +1731,7 @@ export declare const schemaDict: {
|
|
|
1730
1731
|
readonly defs: {
|
|
1731
1732
|
readonly main: {
|
|
1732
1733
|
readonly type: "query";
|
|
1733
|
-
readonly description: "
|
|
1734
|
+
readonly description: "Returns the matched contacts (contacts that were mutually imported). Excludes dismissed matches. Requires authentication.";
|
|
1734
1735
|
readonly parameters: {
|
|
1735
1736
|
readonly type: "params";
|
|
1736
1737
|
readonly properties: {
|
|
@@ -1765,8 +1766,13 @@ export declare const schemaDict: {
|
|
|
1765
1766
|
};
|
|
1766
1767
|
};
|
|
1767
1768
|
readonly errors: [{
|
|
1768
|
-
readonly name: "
|
|
1769
|
-
|
|
1769
|
+
readonly name: "InvalidDid";
|
|
1770
|
+
}, {
|
|
1771
|
+
readonly name: "InvalidLimit";
|
|
1772
|
+
}, {
|
|
1773
|
+
readonly name: "InvalidCursor";
|
|
1774
|
+
}, {
|
|
1775
|
+
readonly name: "InternalError";
|
|
1770
1776
|
}];
|
|
1771
1777
|
};
|
|
1772
1778
|
};
|
|
@@ -1777,7 +1783,7 @@ export declare const schemaDict: {
|
|
|
1777
1783
|
readonly defs: {
|
|
1778
1784
|
readonly main: {
|
|
1779
1785
|
readonly type: "query";
|
|
1780
|
-
readonly description: "
|
|
1786
|
+
readonly description: "Gets the user's current contact import status. Requires authentication.";
|
|
1781
1787
|
readonly parameters: {
|
|
1782
1788
|
readonly type: "params";
|
|
1783
1789
|
readonly properties: {};
|
|
@@ -1796,8 +1802,9 @@ export declare const schemaDict: {
|
|
|
1796
1802
|
};
|
|
1797
1803
|
};
|
|
1798
1804
|
readonly errors: [{
|
|
1799
|
-
readonly name: "
|
|
1800
|
-
|
|
1805
|
+
readonly name: "InvalidDid";
|
|
1806
|
+
}, {
|
|
1807
|
+
readonly name: "InternalError";
|
|
1801
1808
|
}];
|
|
1802
1809
|
};
|
|
1803
1810
|
};
|
|
@@ -1808,7 +1815,7 @@ export declare const schemaDict: {
|
|
|
1808
1815
|
readonly defs: {
|
|
1809
1816
|
readonly main: {
|
|
1810
1817
|
readonly type: "procedure";
|
|
1811
|
-
readonly description: "
|
|
1818
|
+
readonly description: "Import contacts for securely matching with other users. This follows the protocol explained in https://docs.bsky.app/blog/contact-import-rfc. Requires authentication.";
|
|
1812
1819
|
readonly input: {
|
|
1813
1820
|
readonly encoding: "application/json";
|
|
1814
1821
|
readonly schema: {
|
|
@@ -1849,8 +1856,15 @@ export declare const schemaDict: {
|
|
|
1849
1856
|
};
|
|
1850
1857
|
};
|
|
1851
1858
|
readonly errors: [{
|
|
1852
|
-
readonly name: "
|
|
1853
|
-
|
|
1859
|
+
readonly name: "InvalidDid";
|
|
1860
|
+
}, {
|
|
1861
|
+
readonly name: "InvalidContacts";
|
|
1862
|
+
}, {
|
|
1863
|
+
readonly name: "TooManyContacts";
|
|
1864
|
+
}, {
|
|
1865
|
+
readonly name: "InvalidToken";
|
|
1866
|
+
}, {
|
|
1867
|
+
readonly name: "InternalError";
|
|
1854
1868
|
}];
|
|
1855
1869
|
};
|
|
1856
1870
|
};
|
|
@@ -1861,7 +1875,7 @@ export declare const schemaDict: {
|
|
|
1861
1875
|
readonly defs: {
|
|
1862
1876
|
readonly main: {
|
|
1863
1877
|
readonly type: "procedure";
|
|
1864
|
-
readonly description: "
|
|
1878
|
+
readonly description: "Removes all stored hashes used for contact matching, existing matches, and sync status. Requires authentication.";
|
|
1865
1879
|
readonly input: {
|
|
1866
1880
|
readonly encoding: "application/json";
|
|
1867
1881
|
readonly schema: {
|
|
@@ -1877,8 +1891,9 @@ export declare const schemaDict: {
|
|
|
1877
1891
|
};
|
|
1878
1892
|
};
|
|
1879
1893
|
readonly errors: [{
|
|
1880
|
-
readonly name: "
|
|
1881
|
-
|
|
1894
|
+
readonly name: "InvalidDid";
|
|
1895
|
+
}, {
|
|
1896
|
+
readonly name: "InternalError";
|
|
1882
1897
|
}];
|
|
1883
1898
|
};
|
|
1884
1899
|
};
|
|
@@ -1889,7 +1904,7 @@ export declare const schemaDict: {
|
|
|
1889
1904
|
readonly defs: {
|
|
1890
1905
|
readonly main: {
|
|
1891
1906
|
readonly type: "procedure";
|
|
1892
|
-
readonly description: "
|
|
1907
|
+
readonly description: "System endpoint to send notifications related to contact imports. Requires role authentication.";
|
|
1893
1908
|
readonly input: {
|
|
1894
1909
|
readonly encoding: "application/json";
|
|
1895
1910
|
readonly schema: {
|
|
@@ -1925,7 +1940,7 @@ export declare const schemaDict: {
|
|
|
1925
1940
|
readonly defs: {
|
|
1926
1941
|
readonly main: {
|
|
1927
1942
|
readonly type: "procedure";
|
|
1928
|
-
readonly description: "
|
|
1943
|
+
readonly description: "Starts a phone verification flow. The phone passed will receive a code via SMS that should be passed to `app.bsky.contact.verifyPhone`. Requires authentication.";
|
|
1929
1944
|
readonly input: {
|
|
1930
1945
|
readonly encoding: "application/json";
|
|
1931
1946
|
readonly schema: {
|
|
@@ -1947,8 +1962,13 @@ export declare const schemaDict: {
|
|
|
1947
1962
|
};
|
|
1948
1963
|
};
|
|
1949
1964
|
readonly errors: [{
|
|
1950
|
-
readonly name: "
|
|
1951
|
-
|
|
1965
|
+
readonly name: "RateLimitExceeded";
|
|
1966
|
+
}, {
|
|
1967
|
+
readonly name: "InvalidDid";
|
|
1968
|
+
}, {
|
|
1969
|
+
readonly name: "InvalidPhone";
|
|
1970
|
+
}, {
|
|
1971
|
+
readonly name: "InternalError";
|
|
1952
1972
|
}];
|
|
1953
1973
|
};
|
|
1954
1974
|
};
|
|
@@ -1959,7 +1979,7 @@ export declare const schemaDict: {
|
|
|
1959
1979
|
readonly defs: {
|
|
1960
1980
|
readonly main: {
|
|
1961
1981
|
readonly type: "procedure";
|
|
1962
|
-
readonly description: "
|
|
1982
|
+
readonly description: "Verifies control over a phone number with a code received via SMS and starts a contact import session. Requires authentication.";
|
|
1963
1983
|
readonly input: {
|
|
1964
1984
|
readonly encoding: "application/json";
|
|
1965
1985
|
readonly schema: {
|
|
@@ -1991,8 +2011,15 @@ export declare const schemaDict: {
|
|
|
1991
2011
|
};
|
|
1992
2012
|
};
|
|
1993
2013
|
readonly errors: [{
|
|
1994
|
-
readonly name: "
|
|
1995
|
-
|
|
2014
|
+
readonly name: "RateLimitExceeded";
|
|
2015
|
+
}, {
|
|
2016
|
+
readonly name: "InvalidDid";
|
|
2017
|
+
}, {
|
|
2018
|
+
readonly name: "InvalidPhone";
|
|
2019
|
+
}, {
|
|
2020
|
+
readonly name: "InvalidCode";
|
|
2021
|
+
}, {
|
|
2022
|
+
readonly name: "InternalError";
|
|
1996
2023
|
}];
|
|
1997
2024
|
};
|
|
1998
2025
|
};
|
|
@@ -6352,7 +6379,7 @@ export declare const schemaDict: {
|
|
|
6352
6379
|
readonly reason: {
|
|
6353
6380
|
readonly type: "string";
|
|
6354
6381
|
readonly description: "The reason why this notification was delivered - e.g. your post was liked, or you received a new follower.";
|
|
6355
|
-
readonly knownValues: ["like", "repost", "follow", "mention", "reply", "quote", "starterpack-joined", "verified", "unverified", "like-via-repost", "repost-via-repost", "subscribed-post"];
|
|
6382
|
+
readonly knownValues: ["like", "repost", "follow", "mention", "reply", "quote", "starterpack-joined", "verified", "unverified", "like-via-repost", "repost-via-repost", "subscribed-post", "contact-match"];
|
|
6356
6383
|
};
|
|
6357
6384
|
readonly reasonSubject: {
|
|
6358
6385
|
readonly type: "string";
|
|
@@ -12079,7 +12106,12 @@ export declare const schemaDict: {
|
|
|
12079
12106
|
readonly defs: {
|
|
12080
12107
|
readonly main: {
|
|
12081
12108
|
readonly type: "procedure";
|
|
12082
|
-
readonly description: "Delete the current session. Requires auth.";
|
|
12109
|
+
readonly description: "Delete the current session. Requires auth using the 'refreshJwt' (not the 'accessJwt').";
|
|
12110
|
+
readonly errors: [{
|
|
12111
|
+
readonly name: "InvalidToken";
|
|
12112
|
+
}, {
|
|
12113
|
+
readonly name: "ExpiredToken";
|
|
12114
|
+
}];
|
|
12083
12115
|
};
|
|
12084
12116
|
};
|
|
12085
12117
|
};
|
|
@@ -12262,6 +12294,9 @@ export declare const schemaDict: {
|
|
|
12262
12294
|
readonly type: "string";
|
|
12263
12295
|
readonly format: "did";
|
|
12264
12296
|
};
|
|
12297
|
+
readonly didDoc: {
|
|
12298
|
+
readonly type: "unknown";
|
|
12299
|
+
};
|
|
12265
12300
|
readonly email: {
|
|
12266
12301
|
readonly type: "string";
|
|
12267
12302
|
};
|
|
@@ -12271,9 +12306,6 @@ export declare const schemaDict: {
|
|
|
12271
12306
|
readonly emailAuthFactor: {
|
|
12272
12307
|
readonly type: "boolean";
|
|
12273
12308
|
};
|
|
12274
|
-
readonly didDoc: {
|
|
12275
|
-
readonly type: "unknown";
|
|
12276
|
-
};
|
|
12277
12309
|
readonly active: {
|
|
12278
12310
|
readonly type: "boolean";
|
|
12279
12311
|
};
|
|
@@ -12363,6 +12395,15 @@ export declare const schemaDict: {
|
|
|
12363
12395
|
readonly didDoc: {
|
|
12364
12396
|
readonly type: "unknown";
|
|
12365
12397
|
};
|
|
12398
|
+
readonly email: {
|
|
12399
|
+
readonly type: "string";
|
|
12400
|
+
};
|
|
12401
|
+
readonly emailConfirmed: {
|
|
12402
|
+
readonly type: "boolean";
|
|
12403
|
+
};
|
|
12404
|
+
readonly emailAuthFactor: {
|
|
12405
|
+
readonly type: "boolean";
|
|
12406
|
+
};
|
|
12366
12407
|
readonly active: {
|
|
12367
12408
|
readonly type: "boolean";
|
|
12368
12409
|
};
|
|
@@ -12376,6 +12417,10 @@ export declare const schemaDict: {
|
|
|
12376
12417
|
};
|
|
12377
12418
|
readonly errors: [{
|
|
12378
12419
|
readonly name: "AccountTakedown";
|
|
12420
|
+
}, {
|
|
12421
|
+
readonly name: "InvalidToken";
|
|
12422
|
+
}, {
|
|
12423
|
+
readonly name: "ExpiredToken";
|
|
12379
12424
|
}];
|
|
12380
12425
|
};
|
|
12381
12426
|
};
|
|
@@ -20006,7 +20051,7 @@ export declare const schemas: ({
|
|
|
20006
20051
|
readonly defs: {
|
|
20007
20052
|
readonly main: {
|
|
20008
20053
|
readonly type: "procedure";
|
|
20009
|
-
readonly description: "
|
|
20054
|
+
readonly description: "Removes a match that was found via contact import. It shouldn't appear again if the same contact is re-imported. Requires authentication.";
|
|
20010
20055
|
readonly input: {
|
|
20011
20056
|
readonly encoding: "application/json";
|
|
20012
20057
|
readonly schema: {
|
|
@@ -20029,8 +20074,9 @@ export declare const schemas: ({
|
|
|
20029
20074
|
};
|
|
20030
20075
|
};
|
|
20031
20076
|
readonly errors: [{
|
|
20032
|
-
readonly name: "
|
|
20033
|
-
|
|
20077
|
+
readonly name: "InvalidDid";
|
|
20078
|
+
}, {
|
|
20079
|
+
readonly name: "InternalError";
|
|
20034
20080
|
}];
|
|
20035
20081
|
};
|
|
20036
20082
|
};
|
|
@@ -20040,7 +20086,7 @@ export declare const schemas: ({
|
|
|
20040
20086
|
readonly defs: {
|
|
20041
20087
|
readonly main: {
|
|
20042
20088
|
readonly type: "query";
|
|
20043
|
-
readonly description: "
|
|
20089
|
+
readonly description: "Returns the matched contacts (contacts that were mutually imported). Excludes dismissed matches. Requires authentication.";
|
|
20044
20090
|
readonly parameters: {
|
|
20045
20091
|
readonly type: "params";
|
|
20046
20092
|
readonly properties: {
|
|
@@ -20075,8 +20121,13 @@ export declare const schemas: ({
|
|
|
20075
20121
|
};
|
|
20076
20122
|
};
|
|
20077
20123
|
readonly errors: [{
|
|
20078
|
-
readonly name: "
|
|
20079
|
-
|
|
20124
|
+
readonly name: "InvalidDid";
|
|
20125
|
+
}, {
|
|
20126
|
+
readonly name: "InvalidLimit";
|
|
20127
|
+
}, {
|
|
20128
|
+
readonly name: "InvalidCursor";
|
|
20129
|
+
}, {
|
|
20130
|
+
readonly name: "InternalError";
|
|
20080
20131
|
}];
|
|
20081
20132
|
};
|
|
20082
20133
|
};
|
|
@@ -20086,7 +20137,7 @@ export declare const schemas: ({
|
|
|
20086
20137
|
readonly defs: {
|
|
20087
20138
|
readonly main: {
|
|
20088
20139
|
readonly type: "query";
|
|
20089
|
-
readonly description: "
|
|
20140
|
+
readonly description: "Gets the user's current contact import status. Requires authentication.";
|
|
20090
20141
|
readonly parameters: {
|
|
20091
20142
|
readonly type: "params";
|
|
20092
20143
|
readonly properties: {};
|
|
@@ -20105,8 +20156,9 @@ export declare const schemas: ({
|
|
|
20105
20156
|
};
|
|
20106
20157
|
};
|
|
20107
20158
|
readonly errors: [{
|
|
20108
|
-
readonly name: "
|
|
20109
|
-
|
|
20159
|
+
readonly name: "InvalidDid";
|
|
20160
|
+
}, {
|
|
20161
|
+
readonly name: "InternalError";
|
|
20110
20162
|
}];
|
|
20111
20163
|
};
|
|
20112
20164
|
};
|
|
@@ -20116,7 +20168,7 @@ export declare const schemas: ({
|
|
|
20116
20168
|
readonly defs: {
|
|
20117
20169
|
readonly main: {
|
|
20118
20170
|
readonly type: "procedure";
|
|
20119
|
-
readonly description: "
|
|
20171
|
+
readonly description: "Import contacts for securely matching with other users. This follows the protocol explained in https://docs.bsky.app/blog/contact-import-rfc. Requires authentication.";
|
|
20120
20172
|
readonly input: {
|
|
20121
20173
|
readonly encoding: "application/json";
|
|
20122
20174
|
readonly schema: {
|
|
@@ -20157,8 +20209,15 @@ export declare const schemas: ({
|
|
|
20157
20209
|
};
|
|
20158
20210
|
};
|
|
20159
20211
|
readonly errors: [{
|
|
20160
|
-
readonly name: "
|
|
20161
|
-
|
|
20212
|
+
readonly name: "InvalidDid";
|
|
20213
|
+
}, {
|
|
20214
|
+
readonly name: "InvalidContacts";
|
|
20215
|
+
}, {
|
|
20216
|
+
readonly name: "TooManyContacts";
|
|
20217
|
+
}, {
|
|
20218
|
+
readonly name: "InvalidToken";
|
|
20219
|
+
}, {
|
|
20220
|
+
readonly name: "InternalError";
|
|
20162
20221
|
}];
|
|
20163
20222
|
};
|
|
20164
20223
|
};
|
|
@@ -20168,7 +20227,7 @@ export declare const schemas: ({
|
|
|
20168
20227
|
readonly defs: {
|
|
20169
20228
|
readonly main: {
|
|
20170
20229
|
readonly type: "procedure";
|
|
20171
|
-
readonly description: "
|
|
20230
|
+
readonly description: "Removes all stored hashes used for contact matching, existing matches, and sync status. Requires authentication.";
|
|
20172
20231
|
readonly input: {
|
|
20173
20232
|
readonly encoding: "application/json";
|
|
20174
20233
|
readonly schema: {
|
|
@@ -20184,8 +20243,9 @@ export declare const schemas: ({
|
|
|
20184
20243
|
};
|
|
20185
20244
|
};
|
|
20186
20245
|
readonly errors: [{
|
|
20187
|
-
readonly name: "
|
|
20188
|
-
|
|
20246
|
+
readonly name: "InvalidDid";
|
|
20247
|
+
}, {
|
|
20248
|
+
readonly name: "InternalError";
|
|
20189
20249
|
}];
|
|
20190
20250
|
};
|
|
20191
20251
|
};
|
|
@@ -20195,7 +20255,7 @@ export declare const schemas: ({
|
|
|
20195
20255
|
readonly defs: {
|
|
20196
20256
|
readonly main: {
|
|
20197
20257
|
readonly type: "procedure";
|
|
20198
|
-
readonly description: "
|
|
20258
|
+
readonly description: "System endpoint to send notifications related to contact imports. Requires role authentication.";
|
|
20199
20259
|
readonly input: {
|
|
20200
20260
|
readonly encoding: "application/json";
|
|
20201
20261
|
readonly schema: {
|
|
@@ -20230,7 +20290,7 @@ export declare const schemas: ({
|
|
|
20230
20290
|
readonly defs: {
|
|
20231
20291
|
readonly main: {
|
|
20232
20292
|
readonly type: "procedure";
|
|
20233
|
-
readonly description: "
|
|
20293
|
+
readonly description: "Starts a phone verification flow. The phone passed will receive a code via SMS that should be passed to `app.bsky.contact.verifyPhone`. Requires authentication.";
|
|
20234
20294
|
readonly input: {
|
|
20235
20295
|
readonly encoding: "application/json";
|
|
20236
20296
|
readonly schema: {
|
|
@@ -20252,8 +20312,13 @@ export declare const schemas: ({
|
|
|
20252
20312
|
};
|
|
20253
20313
|
};
|
|
20254
20314
|
readonly errors: [{
|
|
20255
|
-
readonly name: "
|
|
20256
|
-
|
|
20315
|
+
readonly name: "RateLimitExceeded";
|
|
20316
|
+
}, {
|
|
20317
|
+
readonly name: "InvalidDid";
|
|
20318
|
+
}, {
|
|
20319
|
+
readonly name: "InvalidPhone";
|
|
20320
|
+
}, {
|
|
20321
|
+
readonly name: "InternalError";
|
|
20257
20322
|
}];
|
|
20258
20323
|
};
|
|
20259
20324
|
};
|
|
@@ -20263,7 +20328,7 @@ export declare const schemas: ({
|
|
|
20263
20328
|
readonly defs: {
|
|
20264
20329
|
readonly main: {
|
|
20265
20330
|
readonly type: "procedure";
|
|
20266
|
-
readonly description: "
|
|
20331
|
+
readonly description: "Verifies control over a phone number with a code received via SMS and starts a contact import session. Requires authentication.";
|
|
20267
20332
|
readonly input: {
|
|
20268
20333
|
readonly encoding: "application/json";
|
|
20269
20334
|
readonly schema: {
|
|
@@ -20295,8 +20360,15 @@ export declare const schemas: ({
|
|
|
20295
20360
|
};
|
|
20296
20361
|
};
|
|
20297
20362
|
readonly errors: [{
|
|
20298
|
-
readonly name: "
|
|
20299
|
-
|
|
20363
|
+
readonly name: "RateLimitExceeded";
|
|
20364
|
+
}, {
|
|
20365
|
+
readonly name: "InvalidDid";
|
|
20366
|
+
}, {
|
|
20367
|
+
readonly name: "InvalidPhone";
|
|
20368
|
+
}, {
|
|
20369
|
+
readonly name: "InvalidCode";
|
|
20370
|
+
}, {
|
|
20371
|
+
readonly name: "InternalError";
|
|
20300
20372
|
}];
|
|
20301
20373
|
};
|
|
20302
20374
|
};
|
|
@@ -24585,7 +24657,7 @@ export declare const schemas: ({
|
|
|
24585
24657
|
readonly reason: {
|
|
24586
24658
|
readonly type: "string";
|
|
24587
24659
|
readonly description: "The reason why this notification was delivered - e.g. your post was liked, or you received a new follower.";
|
|
24588
|
-
readonly knownValues: ["like", "repost", "follow", "mention", "reply", "quote", "starterpack-joined", "verified", "unverified", "like-via-repost", "repost-via-repost", "subscribed-post"];
|
|
24660
|
+
readonly knownValues: ["like", "repost", "follow", "mention", "reply", "quote", "starterpack-joined", "verified", "unverified", "like-via-repost", "repost-via-repost", "subscribed-post", "contact-match"];
|
|
24589
24661
|
};
|
|
24590
24662
|
readonly reasonSubject: {
|
|
24591
24663
|
readonly type: "string";
|
|
@@ -30196,7 +30268,12 @@ export declare const schemas: ({
|
|
|
30196
30268
|
readonly defs: {
|
|
30197
30269
|
readonly main: {
|
|
30198
30270
|
readonly type: "procedure";
|
|
30199
|
-
readonly description: "Delete the current session. Requires auth.";
|
|
30271
|
+
readonly description: "Delete the current session. Requires auth using the 'refreshJwt' (not the 'accessJwt').";
|
|
30272
|
+
readonly errors: [{
|
|
30273
|
+
readonly name: "InvalidToken";
|
|
30274
|
+
}, {
|
|
30275
|
+
readonly name: "ExpiredToken";
|
|
30276
|
+
}];
|
|
30200
30277
|
};
|
|
30201
30278
|
};
|
|
30202
30279
|
} | {
|
|
@@ -30375,6 +30452,9 @@ export declare const schemas: ({
|
|
|
30375
30452
|
readonly type: "string";
|
|
30376
30453
|
readonly format: "did";
|
|
30377
30454
|
};
|
|
30455
|
+
readonly didDoc: {
|
|
30456
|
+
readonly type: "unknown";
|
|
30457
|
+
};
|
|
30378
30458
|
readonly email: {
|
|
30379
30459
|
readonly type: "string";
|
|
30380
30460
|
};
|
|
@@ -30384,9 +30464,6 @@ export declare const schemas: ({
|
|
|
30384
30464
|
readonly emailAuthFactor: {
|
|
30385
30465
|
readonly type: "boolean";
|
|
30386
30466
|
};
|
|
30387
|
-
readonly didDoc: {
|
|
30388
|
-
readonly type: "unknown";
|
|
30389
|
-
};
|
|
30390
30467
|
readonly active: {
|
|
30391
30468
|
readonly type: "boolean";
|
|
30392
30469
|
};
|
|
@@ -30474,6 +30551,15 @@ export declare const schemas: ({
|
|
|
30474
30551
|
readonly didDoc: {
|
|
30475
30552
|
readonly type: "unknown";
|
|
30476
30553
|
};
|
|
30554
|
+
readonly email: {
|
|
30555
|
+
readonly type: "string";
|
|
30556
|
+
};
|
|
30557
|
+
readonly emailConfirmed: {
|
|
30558
|
+
readonly type: "boolean";
|
|
30559
|
+
};
|
|
30560
|
+
readonly emailAuthFactor: {
|
|
30561
|
+
readonly type: "boolean";
|
|
30562
|
+
};
|
|
30477
30563
|
readonly active: {
|
|
30478
30564
|
readonly type: "boolean";
|
|
30479
30565
|
};
|
|
@@ -30487,6 +30573,10 @@ export declare const schemas: ({
|
|
|
30487
30573
|
};
|
|
30488
30574
|
readonly errors: [{
|
|
30489
30575
|
readonly name: "AccountTakedown";
|
|
30576
|
+
}, {
|
|
30577
|
+
readonly name: "InvalidToken";
|
|
30578
|
+
}, {
|
|
30579
|
+
readonly name: "ExpiredToken";
|
|
30490
30580
|
}];
|
|
30491
30581
|
};
|
|
30492
30582
|
};
|