@atproto/api 0.18.4 → 0.18.6
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 +23 -0
- package/dist/agent.d.ts.map +1 -1
- package/dist/agent.js +4 -0
- package/dist/agent.js.map +1 -1
- package/dist/client/index.d.ts +30 -0
- package/dist/client/index.d.ts.map +1 -1
- package/dist/client/index.js +95 -8
- package/dist/client/index.js.map +1 -1
- package/dist/client/lexicons.d.ts +812 -2
- package/dist/client/lexicons.d.ts.map +1 -1
- package/dist/client/lexicons.js +429 -0
- package/dist/client/lexicons.js.map +1 -1
- package/dist/client/types/app/bsky/actor/defs.d.ts +13 -1
- package/dist/client/types/app/bsky/actor/defs.d.ts.map +1 -1
- package/dist/client/types/app/bsky/actor/defs.js +9 -0
- package/dist/client/types/app/bsky/actor/defs.js.map +1 -1
- package/dist/client/types/app/bsky/contact/defs.d.ts +34 -0
- package/dist/client/types/app/bsky/contact/defs.d.ts.map +1 -0
- package/dist/client/types/app/bsky/contact/defs.js +34 -0
- package/dist/client/types/app/bsky/contact/defs.js.map +1 -0
- package/dist/client/types/app/bsky/contact/dismissMatch.d.ts +27 -0
- package/dist/client/types/app/bsky/contact/dismissMatch.d.ts.map +1 -0
- package/dist/client/types/app/bsky/contact/dismissMatch.js +26 -0
- package/dist/client/types/app/bsky/contact/dismissMatch.js.map +1 -0
- package/dist/client/types/app/bsky/contact/getMatches.d.ts +28 -0
- package/dist/client/types/app/bsky/contact/getMatches.d.ts.map +1 -0
- package/dist/client/types/app/bsky/contact/getMatches.js +26 -0
- package/dist/client/types/app/bsky/contact/getMatches.js.map +1 -0
- package/dist/client/types/app/bsky/contact/getSyncStatus.d.ts +24 -0
- package/dist/client/types/app/bsky/contact/getSyncStatus.d.ts.map +1 -0
- package/dist/client/types/app/bsky/contact/getSyncStatus.js +26 -0
- package/dist/client/types/app/bsky/contact/getSyncStatus.js.map +1 -0
- package/dist/client/types/app/bsky/contact/importContacts.d.ts +32 -0
- package/dist/client/types/app/bsky/contact/importContacts.d.ts.map +1 -0
- package/dist/client/types/app/bsky/contact/importContacts.js +26 -0
- package/dist/client/types/app/bsky/contact/importContacts.js.map +1 -0
- package/dist/client/types/app/bsky/contact/removeData.d.ts +25 -0
- package/dist/client/types/app/bsky/contact/removeData.d.ts.map +1 -0
- package/dist/client/types/app/bsky/contact/removeData.js +26 -0
- package/dist/client/types/app/bsky/contact/removeData.js.map +1 -0
- package/dist/client/types/app/bsky/contact/sendNotification.d.ts +26 -0
- package/dist/client/types/app/bsky/contact/sendNotification.d.ts.map +1 -0
- package/dist/client/types/app/bsky/contact/sendNotification.js +11 -0
- package/dist/client/types/app/bsky/contact/sendNotification.js.map +1 -0
- package/dist/client/types/app/bsky/contact/startPhoneVerification.d.ts +27 -0
- package/dist/client/types/app/bsky/contact/startPhoneVerification.d.ts.map +1 -0
- package/dist/client/types/app/bsky/contact/startPhoneVerification.js +26 -0
- package/dist/client/types/app/bsky/contact/startPhoneVerification.js.map +1 -0
- package/dist/client/types/app/bsky/contact/verifyPhone.d.ts +31 -0
- package/dist/client/types/app/bsky/contact/verifyPhone.d.ts.map +1 -0
- package/dist/client/types/app/bsky/contact/verifyPhone.js +26 -0
- package/dist/client/types/app/bsky/contact/verifyPhone.js.map +1 -0
- package/dist/client/types/app/bsky/graph/defs.d.ts +8 -0
- package/dist/client/types/app/bsky/graph/defs.d.ts.map +1 -1
- package/dist/client/types/app/bsky/graph/defs.js.map +1 -1
- package/dist/predicate.d.ts +1 -0
- package/dist/predicate.d.ts.map +1 -1
- package/dist/predicate.js +2 -1
- package/dist/predicate.js.map +1 -1
- package/dist/types.d.ts +6 -0
- package/dist/types.d.ts.map +1 -1
- package/dist/types.js.map +1 -1
- package/package.json +5 -5
- package/src/agent.ts +3 -0
- package/src/client/index.ts +117 -0
- package/src/client/lexicons.ts +456 -0
- package/src/client/types/app/bsky/actor/defs.ts +22 -0
- package/src/client/types/app/bsky/contact/defs.ts +71 -0
- package/src/client/types/app/bsky/contact/dismissMatch.ts +52 -0
- package/src/client/types/app/bsky/contact/getMatches.ts +53 -0
- package/src/client/types/app/bsky/contact/getSyncStatus.ts +49 -0
- package/src/client/types/app/bsky/contact/importContacts.ts +58 -0
- package/src/client/types/app/bsky/contact/removeData.ts +49 -0
- package/src/client/types/app/bsky/contact/sendNotification.ts +44 -0
- package/src/client/types/app/bsky/contact/startPhoneVerification.ts +52 -0
- package/src/client/types/app/bsky/contact/verifyPhone.ts +57 -0
- package/src/client/types/app/bsky/graph/defs.ts +8 -0
- package/src/predicate.ts +3 -0
- package/src/types.ts +6 -0
- package/tests/atp-agent.test.ts +82 -1
- package/tsconfig.build.tsbuildinfo +1 -1
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { HeadersMap, XRPCError } from '@atproto/xrpc';
|
|
5
|
+
export type QueryParams = {};
|
|
6
|
+
export interface InputSchema {
|
|
7
|
+
}
|
|
8
|
+
export interface OutputSchema {
|
|
9
|
+
}
|
|
10
|
+
export interface CallOptions {
|
|
11
|
+
signal?: AbortSignal;
|
|
12
|
+
headers?: HeadersMap;
|
|
13
|
+
qp?: QueryParams;
|
|
14
|
+
encoding?: 'application/json';
|
|
15
|
+
}
|
|
16
|
+
export interface Response {
|
|
17
|
+
success: boolean;
|
|
18
|
+
headers: HeadersMap;
|
|
19
|
+
data: OutputSchema;
|
|
20
|
+
}
|
|
21
|
+
export declare class TODOError extends XRPCError {
|
|
22
|
+
constructor(src: XRPCError);
|
|
23
|
+
}
|
|
24
|
+
export declare function toKnownErr(e: any): any;
|
|
25
|
+
//# sourceMappingURL=removeData.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"removeData.d.ts","sourceRoot":"","sources":["../../../../../../src/client/types/app/bsky/contact/removeData.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,eAAe,CAAA;AAcrD,MAAM,MAAM,WAAW,GAAG,EAAE,CAAA;AAE5B,MAAM,WAAW,WAAW;CAAG;AAE/B,MAAM,WAAW,YAAY;CAAG;AAEhC,MAAM,WAAW,WAAW;IAC1B,MAAM,CAAC,EAAE,WAAW,CAAA;IACpB,OAAO,CAAC,EAAE,UAAU,CAAA;IACpB,EAAE,CAAC,EAAE,WAAW,CAAA;IAChB,QAAQ,CAAC,EAAE,kBAAkB,CAAA;CAC9B;AAED,MAAM,WAAW,QAAQ;IACvB,OAAO,EAAE,OAAO,CAAA;IAChB,OAAO,EAAE,UAAU,CAAA;IACnB,IAAI,EAAE,YAAY,CAAA;CACnB;AAED,qBAAa,SAAU,SAAQ,SAAS;gBAC1B,GAAG,EAAE,SAAS;CAG3B;AAED,wBAAgB,UAAU,CAAC,CAAC,EAAE,GAAG,OAMhC"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.TODOError = void 0;
|
|
4
|
+
exports.toKnownErr = toKnownErr;
|
|
5
|
+
/**
|
|
6
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
7
|
+
*/
|
|
8
|
+
const xrpc_1 = require("@atproto/xrpc");
|
|
9
|
+
const lexicons_1 = require("../../../../lexicons");
|
|
10
|
+
const util_1 = require("../../../../util");
|
|
11
|
+
const is$typed = util_1.is$typed, validate = lexicons_1.validate;
|
|
12
|
+
const id = 'app.bsky.contact.removeData';
|
|
13
|
+
class TODOError extends xrpc_1.XRPCError {
|
|
14
|
+
constructor(src) {
|
|
15
|
+
super(src.status, src.error, src.message, src.headers, { cause: src });
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
exports.TODOError = TODOError;
|
|
19
|
+
function toKnownErr(e) {
|
|
20
|
+
if (e instanceof xrpc_1.XRPCError) {
|
|
21
|
+
if (e.error === 'TODO')
|
|
22
|
+
return new TODOError(e);
|
|
23
|
+
}
|
|
24
|
+
return e;
|
|
25
|
+
}
|
|
26
|
+
//# sourceMappingURL=removeData.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"removeData.js","sourceRoot":"","sources":["../../../../../../src/client/types/app/bsky/contact/removeData.ts"],"names":[],"mappings":";;;AA0CA,gCAMC;AAhDD;;GAEG;AACH,wCAAqD;AAGrD,mDAA4D;AAC5D,2CAIyB;AAEzB,MAAM,QAAQ,GAAG,eAAS,EACxB,QAAQ,GAAG,mBAAS,CAAA;AACtB,MAAM,EAAE,GAAG,6BAA6B,CAAA;AAqBxC,MAAa,SAAU,SAAQ,gBAAS;IACtC,YAAY,GAAc;QACxB,KAAK,CAAC,GAAG,CAAC,MAAM,EAAE,GAAG,CAAC,KAAK,EAAE,GAAG,CAAC,OAAO,EAAE,GAAG,CAAC,OAAO,EAAE,EAAE,KAAK,EAAE,GAAG,EAAE,CAAC,CAAA;IACxE,CAAC;CACF;AAJD,8BAIC;AAED,SAAgB,UAAU,CAAC,CAAM;IAC/B,IAAI,CAAC,YAAY,gBAAS,EAAE,CAAC;QAC3B,IAAI,CAAC,CAAC,KAAK,KAAK,MAAM;YAAE,OAAO,IAAI,SAAS,CAAC,CAAC,CAAC,CAAA;IACjD,CAAC;IAED,OAAO,CAAC,CAAA;AACV,CAAC","sourcesContent":["/**\n * GENERATED CODE - DO NOT MODIFY\n */\nimport { HeadersMap, XRPCError } from '@atproto/xrpc'\nimport { type ValidationResult, BlobRef } from '@atproto/lexicon'\nimport { CID } from 'multiformats/cid'\nimport { validate as _validate } from '../../../../lexicons'\nimport {\n type $Typed,\n is$typed as _is$typed,\n type OmitKey,\n} from '../../../../util'\n\nconst is$typed = _is$typed,\n validate = _validate\nconst id = 'app.bsky.contact.removeData'\n\nexport type QueryParams = {}\n\nexport interface InputSchema {}\n\nexport interface OutputSchema {}\n\nexport interface CallOptions {\n signal?: AbortSignal\n headers?: HeadersMap\n qp?: QueryParams\n encoding?: 'application/json'\n}\n\nexport interface Response {\n success: boolean\n headers: HeadersMap\n data: OutputSchema\n}\n\nexport class TODOError extends XRPCError {\n constructor(src: XRPCError) {\n super(src.status, src.error, src.message, src.headers, { cause: src })\n }\n}\n\nexport function toKnownErr(e: any) {\n if (e instanceof XRPCError) {\n if (e.error === 'TODO') return new TODOError(e)\n }\n\n return e\n}\n"]}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { HeadersMap } from '@atproto/xrpc';
|
|
5
|
+
export type QueryParams = {};
|
|
6
|
+
export interface InputSchema {
|
|
7
|
+
/** The DID of who this notification comes from. */
|
|
8
|
+
from: string;
|
|
9
|
+
/** The DID of who this notification should go to. */
|
|
10
|
+
to: string;
|
|
11
|
+
}
|
|
12
|
+
export interface OutputSchema {
|
|
13
|
+
}
|
|
14
|
+
export interface CallOptions {
|
|
15
|
+
signal?: AbortSignal;
|
|
16
|
+
headers?: HeadersMap;
|
|
17
|
+
qp?: QueryParams;
|
|
18
|
+
encoding?: 'application/json';
|
|
19
|
+
}
|
|
20
|
+
export interface Response {
|
|
21
|
+
success: boolean;
|
|
22
|
+
headers: HeadersMap;
|
|
23
|
+
data: OutputSchema;
|
|
24
|
+
}
|
|
25
|
+
export declare function toKnownErr(e: any): any;
|
|
26
|
+
//# sourceMappingURL=sendNotification.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sendNotification.d.ts","sourceRoot":"","sources":["../../../../../../src/client/types/app/bsky/contact/sendNotification.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAAE,UAAU,EAAa,MAAM,eAAe,CAAA;AAcrD,MAAM,MAAM,WAAW,GAAG,EAAE,CAAA;AAE5B,MAAM,WAAW,WAAW;IAC1B,mDAAmD;IACnD,IAAI,EAAE,MAAM,CAAA;IACZ,qDAAqD;IACrD,EAAE,EAAE,MAAM,CAAA;CACX;AAED,MAAM,WAAW,YAAY;CAAG;AAEhC,MAAM,WAAW,WAAW;IAC1B,MAAM,CAAC,EAAE,WAAW,CAAA;IACpB,OAAO,CAAC,EAAE,UAAU,CAAA;IACpB,EAAE,CAAC,EAAE,WAAW,CAAA;IAChB,QAAQ,CAAC,EAAE,kBAAkB,CAAA;CAC9B;AAED,MAAM,WAAW,QAAQ;IACvB,OAAO,EAAE,OAAO,CAAA;IAChB,OAAO,EAAE,UAAU,CAAA;IACnB,IAAI,EAAE,YAAY,CAAA;CACnB;AAED,wBAAgB,UAAU,CAAC,CAAC,EAAE,GAAG,OAEhC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.toKnownErr = toKnownErr;
|
|
4
|
+
const lexicons_1 = require("../../../../lexicons");
|
|
5
|
+
const util_1 = require("../../../../util");
|
|
6
|
+
const is$typed = util_1.is$typed, validate = lexicons_1.validate;
|
|
7
|
+
const id = 'app.bsky.contact.sendNotification';
|
|
8
|
+
function toKnownErr(e) {
|
|
9
|
+
return e;
|
|
10
|
+
}
|
|
11
|
+
//# sourceMappingURL=sendNotification.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sendNotification.js","sourceRoot":"","sources":["../../../../../../src/client/types/app/bsky/contact/sendNotification.ts"],"names":[],"mappings":";;AAyCA,gCAEC;AArCD,mDAA4D;AAC5D,2CAIyB;AAEzB,MAAM,QAAQ,GAAG,eAAS,EACxB,QAAQ,GAAG,mBAAS,CAAA;AACtB,MAAM,EAAE,GAAG,mCAAmC,CAAA;AA0B9C,SAAgB,UAAU,CAAC,CAAM;IAC/B,OAAO,CAAC,CAAA;AACV,CAAC","sourcesContent":["/**\n * GENERATED CODE - DO NOT MODIFY\n */\nimport { HeadersMap, XRPCError } from '@atproto/xrpc'\nimport { type ValidationResult, BlobRef } from '@atproto/lexicon'\nimport { CID } from 'multiformats/cid'\nimport { validate as _validate } from '../../../../lexicons'\nimport {\n type $Typed,\n is$typed as _is$typed,\n type OmitKey,\n} from '../../../../util'\n\nconst is$typed = _is$typed,\n validate = _validate\nconst id = 'app.bsky.contact.sendNotification'\n\nexport type QueryParams = {}\n\nexport interface InputSchema {\n /** The DID of who this notification comes from. */\n from: string\n /** The DID of who this notification should go to. */\n to: string\n}\n\nexport interface OutputSchema {}\n\nexport interface CallOptions {\n signal?: AbortSignal\n headers?: HeadersMap\n qp?: QueryParams\n encoding?: 'application/json'\n}\n\nexport interface Response {\n success: boolean\n headers: HeadersMap\n data: OutputSchema\n}\n\nexport function toKnownErr(e: any) {\n return e\n}\n"]}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { HeadersMap, XRPCError } from '@atproto/xrpc';
|
|
5
|
+
export type QueryParams = {};
|
|
6
|
+
export interface InputSchema {
|
|
7
|
+
/** The phone number to receive the code via SMS. */
|
|
8
|
+
phone: string;
|
|
9
|
+
}
|
|
10
|
+
export interface OutputSchema {
|
|
11
|
+
}
|
|
12
|
+
export interface CallOptions {
|
|
13
|
+
signal?: AbortSignal;
|
|
14
|
+
headers?: HeadersMap;
|
|
15
|
+
qp?: QueryParams;
|
|
16
|
+
encoding?: 'application/json';
|
|
17
|
+
}
|
|
18
|
+
export interface Response {
|
|
19
|
+
success: boolean;
|
|
20
|
+
headers: HeadersMap;
|
|
21
|
+
data: OutputSchema;
|
|
22
|
+
}
|
|
23
|
+
export declare class TODOError extends XRPCError {
|
|
24
|
+
constructor(src: XRPCError);
|
|
25
|
+
}
|
|
26
|
+
export declare function toKnownErr(e: any): any;
|
|
27
|
+
//# sourceMappingURL=startPhoneVerification.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"startPhoneVerification.d.ts","sourceRoot":"","sources":["../../../../../../src/client/types/app/bsky/contact/startPhoneVerification.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,eAAe,CAAA;AAcrD,MAAM,MAAM,WAAW,GAAG,EAAE,CAAA;AAE5B,MAAM,WAAW,WAAW;IAC1B,oDAAoD;IACpD,KAAK,EAAE,MAAM,CAAA;CACd;AAED,MAAM,WAAW,YAAY;CAAG;AAEhC,MAAM,WAAW,WAAW;IAC1B,MAAM,CAAC,EAAE,WAAW,CAAA;IACpB,OAAO,CAAC,EAAE,UAAU,CAAA;IACpB,EAAE,CAAC,EAAE,WAAW,CAAA;IAChB,QAAQ,CAAC,EAAE,kBAAkB,CAAA;CAC9B;AAED,MAAM,WAAW,QAAQ;IACvB,OAAO,EAAE,OAAO,CAAA;IAChB,OAAO,EAAE,UAAU,CAAA;IACnB,IAAI,EAAE,YAAY,CAAA;CACnB;AAED,qBAAa,SAAU,SAAQ,SAAS;gBAC1B,GAAG,EAAE,SAAS;CAG3B;AAED,wBAAgB,UAAU,CAAC,CAAC,EAAE,GAAG,OAMhC"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.TODOError = void 0;
|
|
4
|
+
exports.toKnownErr = toKnownErr;
|
|
5
|
+
/**
|
|
6
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
7
|
+
*/
|
|
8
|
+
const xrpc_1 = require("@atproto/xrpc");
|
|
9
|
+
const lexicons_1 = require("../../../../lexicons");
|
|
10
|
+
const util_1 = require("../../../../util");
|
|
11
|
+
const is$typed = util_1.is$typed, validate = lexicons_1.validate;
|
|
12
|
+
const id = 'app.bsky.contact.startPhoneVerification';
|
|
13
|
+
class TODOError extends xrpc_1.XRPCError {
|
|
14
|
+
constructor(src) {
|
|
15
|
+
super(src.status, src.error, src.message, src.headers, { cause: src });
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
exports.TODOError = TODOError;
|
|
19
|
+
function toKnownErr(e) {
|
|
20
|
+
if (e instanceof xrpc_1.XRPCError) {
|
|
21
|
+
if (e.error === 'TODO')
|
|
22
|
+
return new TODOError(e);
|
|
23
|
+
}
|
|
24
|
+
return e;
|
|
25
|
+
}
|
|
26
|
+
//# sourceMappingURL=startPhoneVerification.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"startPhoneVerification.js","sourceRoot":"","sources":["../../../../../../src/client/types/app/bsky/contact/startPhoneVerification.ts"],"names":[],"mappings":";;;AA6CA,gCAMC;AAnDD;;GAEG;AACH,wCAAqD;AAGrD,mDAA4D;AAC5D,2CAIyB;AAEzB,MAAM,QAAQ,GAAG,eAAS,EACxB,QAAQ,GAAG,mBAAS,CAAA;AACtB,MAAM,EAAE,GAAG,yCAAyC,CAAA;AAwBpD,MAAa,SAAU,SAAQ,gBAAS;IACtC,YAAY,GAAc;QACxB,KAAK,CAAC,GAAG,CAAC,MAAM,EAAE,GAAG,CAAC,KAAK,EAAE,GAAG,CAAC,OAAO,EAAE,GAAG,CAAC,OAAO,EAAE,EAAE,KAAK,EAAE,GAAG,EAAE,CAAC,CAAA;IACxE,CAAC;CACF;AAJD,8BAIC;AAED,SAAgB,UAAU,CAAC,CAAM;IAC/B,IAAI,CAAC,YAAY,gBAAS,EAAE,CAAC;QAC3B,IAAI,CAAC,CAAC,KAAK,KAAK,MAAM;YAAE,OAAO,IAAI,SAAS,CAAC,CAAC,CAAC,CAAA;IACjD,CAAC;IAED,OAAO,CAAC,CAAA;AACV,CAAC","sourcesContent":["/**\n * GENERATED CODE - DO NOT MODIFY\n */\nimport { HeadersMap, XRPCError } from '@atproto/xrpc'\nimport { type ValidationResult, BlobRef } from '@atproto/lexicon'\nimport { CID } from 'multiformats/cid'\nimport { validate as _validate } from '../../../../lexicons'\nimport {\n type $Typed,\n is$typed as _is$typed,\n type OmitKey,\n} from '../../../../util'\n\nconst is$typed = _is$typed,\n validate = _validate\nconst id = 'app.bsky.contact.startPhoneVerification'\n\nexport type QueryParams = {}\n\nexport interface InputSchema {\n /** The phone number to receive the code via SMS. */\n phone: string\n}\n\nexport interface OutputSchema {}\n\nexport interface CallOptions {\n signal?: AbortSignal\n headers?: HeadersMap\n qp?: QueryParams\n encoding?: 'application/json'\n}\n\nexport interface Response {\n success: boolean\n headers: HeadersMap\n data: OutputSchema\n}\n\nexport class TODOError extends XRPCError {\n constructor(src: XRPCError) {\n super(src.status, src.error, src.message, src.headers, { cause: src })\n }\n}\n\nexport function toKnownErr(e: any) {\n if (e instanceof XRPCError) {\n if (e.error === 'TODO') return new TODOError(e)\n }\n\n return e\n}\n"]}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
3
|
+
*/
|
|
4
|
+
import { HeadersMap, XRPCError } from '@atproto/xrpc';
|
|
5
|
+
export type QueryParams = {};
|
|
6
|
+
export interface InputSchema {
|
|
7
|
+
/** The phone number to verify. Should be the same as the one passed to `app.bsky.contact.startPhoneVerification`. */
|
|
8
|
+
phone: string;
|
|
9
|
+
/** The code received via SMS as a result of the call to `app.bsky.contact.startPhoneVerification`. */
|
|
10
|
+
code: string;
|
|
11
|
+
}
|
|
12
|
+
export interface OutputSchema {
|
|
13
|
+
/** JWT to be used in a call to `app.bsky.contact.importContacts`. It is only valid for a single call. */
|
|
14
|
+
token: string;
|
|
15
|
+
}
|
|
16
|
+
export interface CallOptions {
|
|
17
|
+
signal?: AbortSignal;
|
|
18
|
+
headers?: HeadersMap;
|
|
19
|
+
qp?: QueryParams;
|
|
20
|
+
encoding?: 'application/json';
|
|
21
|
+
}
|
|
22
|
+
export interface Response {
|
|
23
|
+
success: boolean;
|
|
24
|
+
headers: HeadersMap;
|
|
25
|
+
data: OutputSchema;
|
|
26
|
+
}
|
|
27
|
+
export declare class TODOError extends XRPCError {
|
|
28
|
+
constructor(src: XRPCError);
|
|
29
|
+
}
|
|
30
|
+
export declare function toKnownErr(e: any): any;
|
|
31
|
+
//# sourceMappingURL=verifyPhone.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"verifyPhone.d.ts","sourceRoot":"","sources":["../../../../../../src/client/types/app/bsky/contact/verifyPhone.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,eAAe,CAAA;AAcrD,MAAM,MAAM,WAAW,GAAG,EAAE,CAAA;AAE5B,MAAM,WAAW,WAAW;IAC1B,qHAAqH;IACrH,KAAK,EAAE,MAAM,CAAA;IACb,sGAAsG;IACtG,IAAI,EAAE,MAAM,CAAA;CACb;AAED,MAAM,WAAW,YAAY;IAC3B,yGAAyG;IACzG,KAAK,EAAE,MAAM,CAAA;CACd;AAED,MAAM,WAAW,WAAW;IAC1B,MAAM,CAAC,EAAE,WAAW,CAAA;IACpB,OAAO,CAAC,EAAE,UAAU,CAAA;IACpB,EAAE,CAAC,EAAE,WAAW,CAAA;IAChB,QAAQ,CAAC,EAAE,kBAAkB,CAAA;CAC9B;AAED,MAAM,WAAW,QAAQ;IACvB,OAAO,EAAE,OAAO,CAAA;IAChB,OAAO,EAAE,UAAU,CAAA;IACnB,IAAI,EAAE,YAAY,CAAA;CACnB;AAED,qBAAa,SAAU,SAAQ,SAAS;gBAC1B,GAAG,EAAE,SAAS;CAG3B;AAED,wBAAgB,UAAU,CAAC,CAAC,EAAE,GAAG,OAMhC"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.TODOError = void 0;
|
|
4
|
+
exports.toKnownErr = toKnownErr;
|
|
5
|
+
/**
|
|
6
|
+
* GENERATED CODE - DO NOT MODIFY
|
|
7
|
+
*/
|
|
8
|
+
const xrpc_1 = require("@atproto/xrpc");
|
|
9
|
+
const lexicons_1 = require("../../../../lexicons");
|
|
10
|
+
const util_1 = require("../../../../util");
|
|
11
|
+
const is$typed = util_1.is$typed, validate = lexicons_1.validate;
|
|
12
|
+
const id = 'app.bsky.contact.verifyPhone';
|
|
13
|
+
class TODOError extends xrpc_1.XRPCError {
|
|
14
|
+
constructor(src) {
|
|
15
|
+
super(src.status, src.error, src.message, src.headers, { cause: src });
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
exports.TODOError = TODOError;
|
|
19
|
+
function toKnownErr(e) {
|
|
20
|
+
if (e instanceof xrpc_1.XRPCError) {
|
|
21
|
+
if (e.error === 'TODO')
|
|
22
|
+
return new TODOError(e);
|
|
23
|
+
}
|
|
24
|
+
return e;
|
|
25
|
+
}
|
|
26
|
+
//# sourceMappingURL=verifyPhone.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"verifyPhone.js","sourceRoot":"","sources":["../../../../../../src/client/types/app/bsky/contact/verifyPhone.ts"],"names":[],"mappings":";;;AAkDA,gCAMC;AAxDD;;GAEG;AACH,wCAAqD;AAGrD,mDAA4D;AAC5D,2CAIyB;AAEzB,MAAM,QAAQ,GAAG,eAAS,EACxB,QAAQ,GAAG,mBAAS,CAAA;AACtB,MAAM,EAAE,GAAG,8BAA8B,CAAA;AA6BzC,MAAa,SAAU,SAAQ,gBAAS;IACtC,YAAY,GAAc;QACxB,KAAK,CAAC,GAAG,CAAC,MAAM,EAAE,GAAG,CAAC,KAAK,EAAE,GAAG,CAAC,OAAO,EAAE,GAAG,CAAC,OAAO,EAAE,EAAE,KAAK,EAAE,GAAG,EAAE,CAAC,CAAA;IACxE,CAAC;CACF;AAJD,8BAIC;AAED,SAAgB,UAAU,CAAC,CAAM;IAC/B,IAAI,CAAC,YAAY,gBAAS,EAAE,CAAC;QAC3B,IAAI,CAAC,CAAC,KAAK,KAAK,MAAM;YAAE,OAAO,IAAI,SAAS,CAAC,CAAC,CAAC,CAAA;IACjD,CAAC;IAED,OAAO,CAAC,CAAA;AACV,CAAC","sourcesContent":["/**\n * GENERATED CODE - DO NOT MODIFY\n */\nimport { HeadersMap, XRPCError } from '@atproto/xrpc'\nimport { type ValidationResult, BlobRef } from '@atproto/lexicon'\nimport { CID } from 'multiformats/cid'\nimport { validate as _validate } from '../../../../lexicons'\nimport {\n type $Typed,\n is$typed as _is$typed,\n type OmitKey,\n} from '../../../../util'\n\nconst is$typed = _is$typed,\n validate = _validate\nconst id = 'app.bsky.contact.verifyPhone'\n\nexport type QueryParams = {}\n\nexport interface InputSchema {\n /** The phone number to verify. Should be the same as the one passed to `app.bsky.contact.startPhoneVerification`. */\n phone: string\n /** The code received via SMS as a result of the call to `app.bsky.contact.startPhoneVerification`. */\n code: string\n}\n\nexport interface OutputSchema {\n /** JWT to be used in a call to `app.bsky.contact.importContacts`. It is only valid for a single call. */\n token: string\n}\n\nexport interface CallOptions {\n signal?: AbortSignal\n headers?: HeadersMap\n qp?: QueryParams\n encoding?: 'application/json'\n}\n\nexport interface Response {\n success: boolean\n headers: HeadersMap\n data: OutputSchema\n}\n\nexport class TODOError extends XRPCError {\n constructor(src: XRPCError) {\n super(src.status, src.error, src.message, src.headers, { cause: src })\n }\n}\n\nexport function toKnownErr(e: any) {\n if (e instanceof XRPCError) {\n if (e.error === 'TODO') return new TODOError(e)\n }\n\n return e\n}\n"]}
|
|
@@ -108,6 +108,14 @@ export interface Relationship {
|
|
|
108
108
|
following?: string;
|
|
109
109
|
/** if the actor is followed by this DID, contains the AT-URI of the follow record */
|
|
110
110
|
followedBy?: string;
|
|
111
|
+
/** if the actor blocks this DID, this is the AT-URI of the block record */
|
|
112
|
+
blocking?: string;
|
|
113
|
+
/** if the actor is blocked by this DID, contains the AT-URI of the block record */
|
|
114
|
+
blockedBy?: string;
|
|
115
|
+
/** if the actor blocks this DID via a block list, this is the AT-URI of the listblock record */
|
|
116
|
+
blockingByList?: string;
|
|
117
|
+
/** if the actor is blocked by this DID via a block list, contains the AT-URI of the listblock record */
|
|
118
|
+
blockedByList?: string;
|
|
111
119
|
}
|
|
112
120
|
export declare function isRelationship<V>(v: V): v is import("../../../../util").$TypedObject<V, "app.bsky.graph.defs", "relationship">;
|
|
113
121
|
export declare function validateRelationship<V>(v: V): ValidationResult<Relationship & V>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"defs.d.ts","sourceRoot":"","sources":["../../../../../../src/client/types/app/bsky/graph/defs.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAAE,KAAK,gBAAgB,EAAW,MAAM,kBAAkB,CAAA;AAQjE,OAAO,KAAK,KAAK,mBAAmB,MAAM,oCAAoC,CAAA;AAC9E,OAAO,KAAK,KAAK,gBAAgB,MAAM,kBAAkB,CAAA;AACzD,OAAO,KAAK,KAAK,oBAAoB,MAAM,sBAAsB,CAAA;AACjE,OAAO,KAAK,KAAK,eAAe,MAAM,iBAAiB,CAAA;AAMvD,MAAM,WAAW,aAAa;IAC5B,KAAK,CAAC,EAAE,mCAAmC,CAAA;IAC3C,GAAG,EAAE,MAAM,CAAA;IACX,GAAG,EAAE,MAAM,CAAA;IACX,IAAI,EAAE,MAAM,CAAA;IACZ,OAAO,EAAE,WAAW,CAAA;IACpB,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,MAAM,CAAC,EAAE,mBAAmB,CAAC,KAAK,EAAE,CAAA;IACpC,MAAM,CAAC,EAAE,eAAe,CAAA;IACxB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAID,wBAAgB,eAAe,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,2FAEtC;AAED,wBAAgB,qBAAqB,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,uCAE5C;AAED,MAAM,WAAW,QAAQ;IACvB,KAAK,CAAC,EAAE,8BAA8B,CAAA;IACtC,GAAG,EAAE,MAAM,CAAA;IACX,GAAG,EAAE,MAAM,CAAA;IACX,OAAO,EAAE,gBAAgB,CAAC,WAAW,CAAA;IACrC,IAA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wBAAgB,oBAAoB,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,sCAE3C"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"defs.js","sourceRoot":"","sources":["../../../../../../src/client/types/app/bsky/graph/defs.ts"],"names":[],"mappings":";;;AAmCA,0CAEC;AAED,sDAEC;AAoBD,gCAEC;AAED,4CAEC;AAUD,wCAEC;AAED,oDAEC;AAmBD,8CAEC;AAED,0DAEC;AAiBD,wDAEC;AAED,oEAEC;AAuBD,8CAEC;AAED,0DAEC;AAWD,0CAEC;AAED,sDAEC;
|
|
1
|
+
{"version":3,"file":"defs.js","sourceRoot":"","sources":["../../../../../../src/client/types/app/bsky/graph/defs.ts"],"names":[],"mappings":";;;AAmCA,0CAEC;AAED,sDAEC;AAoBD,gCAEC;AAED,4CAEC;AAUD,wCAEC;AAED,oDAEC;AAmBD,8CAEC;AAED,0DAEC;AAiBD,wDAEC;AAED,oEAEC;AAuBD,8CAEC;AAED,0DAEC;AAWD,0CAEC;AAED,sDAEC;AAsBD,wCAEC;AAED,oDAEC;AAxMD,mDAA4D;AAC5D,2CAIyB;AAMzB,MAAM,QAAQ,GAAG,eAAS,EACxB,QAAQ,GAAG,mBAAS,CAAA;AACtB,MAAM,EAAE,GAAG,qBAAqB,CAAA;AAehC,MAAM,iBAAiB,GAAG,eAAe,CAAA;AAEzC,SAAgB,eAAe,CAAI,CAAI;IACrC,OAAO,QAAQ,CAAC,CAAC,EAAE,EAAE,EAAE,iBAAiB,CAAC,CAAA;AAC3C,CAAC;AAED,SAAgB,qBAAqB,CAAI,CAAI;IAC3C,OAAO,QAAQ,CAAoB,CAAC,EAAE,EAAE,EAAE,iBAAiB,CAAC,CAAA;AAC9D,CAAC;AAkBD,MAAM,YAAY,GAAG,UAAU,CAAA;AAE/B,SAAgB,UAAU,CAAI,CAAI;IAChC,OAAO,QAAQ,CAAC,CAAC,EAAE,EAAE,EAAE,YAAY,CAAC,CAAA;AACtC,CAAC;AAED,SA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AAE,EAAE,EAAE,mBAAmB,CAAC,CAAA;AAC7C,CAAC;AAED,SAAgB,uBAAuB,CAAI,CAAI;IAC7C,OAAO,QAAQ,CAAsB,CAAC,EAAE,EAAE,EAAE,mBAAmB,CAAC,CAAA;AAClE,CAAC;AASD,MAAM,iBAAiB,GAAG,eAAe,CAAA;AAEzC,SAAgB,eAAe,CAAI,CAAI;IACrC,OAAO,QAAQ,CAAC,CAAC,EAAE,EAAE,EAAE,iBAAiB,CAAC,CAAA;AAC3C,CAAC;AAED,SAAgB,qBAAqB,CAAI,CAAI;IAC3C,OAAO,QAAQ,CAAoB,CAAC,EAAE,EAAE,EAAE,iBAAiB,CAAC,CAAA;AAC9D,CAAC;AAoBD,MAAM,gBAAgB,GAAG,cAAc,CAAA;AAEvC,SAAgB,cAAc,CAAI,CAAI;IACpC,OAAO,QAAQ,CAAC,CAAC,EAAE,EAAE,EAAE,gBAAgB,CAAC,CAAA;AAC1C,CAAC;AAED,SAAgB,oBAAoB,CAAI,CAAI;IAC1C,OAAO,QAAQ,CAAmB,CAAC,EAAE,EAAE,EAAE,gBAAgB,CAAC,CAAA;AAC5D,CAAC","sourcesContent":["/**\n * GENERATED CODE - DO NOT MODIFY\n */\nimport { type ValidationResult, BlobRef } from '@atproto/lexicon'\nimport { CID } from 'multiformats/cid'\nimport { validate as _validate } from '../../../../lexicons'\nimport {\n type $Typed,\n is$typed as _is$typed,\n type OmitKey,\n} from '../../../../util'\nimport type * as ComAtprotoLabelDefs from '../../../com/atproto/label/defs.js'\nimport type * as AppBskyActorDefs from '../actor/defs.js'\nimport type * as AppBskyRichtextFacet from '../richtext/facet.js'\nimport type * as AppBskyFeedDefs from '../feed/defs.js'\n\nconst is$typed = _is$typed,\n validate = _validate\nconst id = 'app.bsky.graph.defs'\n\nexport interface ListViewBasic {\n $type?: 'app.bsky.graph.defs#listViewBasic'\n uri: string\n cid: string\n name: string\n purpose: ListPurpose\n avatar?: string\n listItemCount?: number\n labels?: ComAtprotoLabelDefs.Label[]\n viewer?: ListViewerState\n indexedAt?: string\n}\n\nconst hashListViewBasic = 'listViewBasic'\n\nexport function isListViewBasic<V>(v: V) {\n return is$typed(v, id, hashListViewBasic)\n}\n\nexport function validateListViewBasic<V>(v: V) {\n return validate<ListViewBasic & V>(v, id, hashListViewBasic)\n}\n\nexport interface ListView {\n $type?: 'app.bsky.graph.defs#listView'\n uri: string\n cid: string\n creator: AppBskyActorDefs.ProfileView\n name: string\n purpose: ListPurpose\n description?: string\n descriptionFacets?: AppBskyRichtextFacet.Main[]\n avatar?: string\n listItemCount?: number\n labels?: ComAtprotoLabelDefs.Label[]\n viewer?: ListViewerState\n indexedAt: string\n}\n\nconst hashListView = 'listView'\n\nexport function isListView<V>(v: V) {\n return is$typed(v, id, hashListView)\n}\n\nexport function validateListView<V>(v: V) {\n return validate<ListView & V>(v, id, hashListView)\n}\n\nexport interface ListItemView {\n $type?: 'app.bsky.graph.defs#listItemView'\n uri: string\n subject: AppBskyActorDefs.ProfileView\n}\n\nconst hashListItemView = 'listItemView'\n\nexport function isListItemView<V>(v: V) {\n return is$typed(v, id, hashListItemView)\n}\n\nexport function validateListItemView<V>(v: V) {\n return validate<ListItemView & V>(v, id, hashListItemView)\n}\n\nexport interface StarterPackView {\n $type?: 'app.bsky.graph.defs#starterPackView'\n uri: string\n cid: string\n record: { [_ in string]: unknown }\n creator: AppBskyActorDefs.ProfileViewBasic\n list?: ListViewBasic\n listItemsSample?: ListItemView[]\n feeds?: AppBskyFeedDefs.GeneratorView[]\n joinedWeekCount?: number\n joinedAllTimeCount?: number\n labels?: ComAtprotoLabelDefs.Label[]\n indexedAt: string\n}\n\nconst hashStarterPackView = 'starterPackView'\n\nexport function isStarterPackView<V>(v: V) {\n return is$typed(v, id, hashStarterPackView)\n}\n\nexport function validateStarterPackView<V>(v: V) {\n return validate<StarterPackView & V>(v, id, hashStarterPackView)\n}\n\nexport interface StarterPackViewBasic {\n $type?: 'app.bsky.graph.defs#starterPackViewBasic'\n uri: string\n cid: string\n record: { [_ in string]: unknown }\n creator: AppBskyActorDefs.ProfileViewBasic\n listItemCount?: number\n joinedWeekCount?: number\n joinedAllTimeCount?: number\n labels?: ComAtprotoLabelDefs.Label[]\n indexedAt: string\n}\n\nconst hashStarterPackViewBasic = 'starterPackViewBasic'\n\nexport function isStarterPackViewBasic<V>(v: V) {\n return is$typed(v, id, hashStarterPackViewBasic)\n}\n\nexport function validateStarterPackViewBasic<V>(v: V) {\n return validate<StarterPackViewBasic & V>(v, id, hashStarterPackViewBasic)\n}\n\nexport type ListPurpose =\n | 'app.bsky.graph.defs#modlist'\n | 'app.bsky.graph.defs#curatelist'\n | 'app.bsky.graph.defs#referencelist'\n | (string & {})\n\n/** A list of actors to apply an aggregate moderation action (mute/block) on. */\nexport const MODLIST = `${id}#modlist`\n/** A list of actors used for curation purposes such as list feeds or interaction gating. */\nexport const CURATELIST = `${id}#curatelist`\n/** A list of actors used for only for reference purposes such as within a starter pack. */\nexport const REFERENCELIST = `${id}#referencelist`\n\nexport interface ListViewerState {\n $type?: 'app.bsky.graph.defs#listViewerState'\n muted?: boolean\n blocked?: string\n}\n\nconst hashListViewerState = 'listViewerState'\n\nexport function isListViewerState<V>(v: V) {\n return is$typed(v, id, hashListViewerState)\n}\n\nexport function validateListViewerState<V>(v: V) {\n return validate<ListViewerState & V>(v, id, hashListViewerState)\n}\n\n/** indicates that a handle or DID could not be resolved */\nexport interface NotFoundActor {\n $type?: 'app.bsky.graph.defs#notFoundActor'\n actor: string\n notFound: true\n}\n\nconst hashNotFoundActor = 'notFoundActor'\n\nexport function isNotFoundActor<V>(v: V) {\n return is$typed(v, id, hashNotFoundActor)\n}\n\nexport function validateNotFoundActor<V>(v: V) {\n return validate<NotFoundActor & V>(v, id, hashNotFoundActor)\n}\n\n/** lists the bi-directional graph relationships between one actor (not indicated in the object), and the target actors (the DID included in the object) */\nexport interface Relationship {\n $type?: 'app.bsky.graph.defs#relationship'\n did: string\n /** if the actor follows this DID, this is the AT-URI of the follow record */\n following?: string\n /** if the actor is followed by this DID, contains the AT-URI of the follow record */\n followedBy?: string\n /** if the actor blocks this DID, this is the AT-URI of the block record */\n blocking?: string\n /** if the actor is blocked by this DID, contains the AT-URI of the block record */\n blockedBy?: string\n /** if the actor blocks this DID via a block list, this is the AT-URI of the listblock record */\n blockingByList?: string\n /** if the actor is blocked by this DID via a block list, contains the AT-URI of the listblock record */\n blockedByList?: string\n}\n\nconst hashRelationship = 'relationship'\n\nexport function isRelationship<V>(v: V) {\n return is$typed(v, id, hashRelationship)\n}\n\nexport function validateRelationship<V>(v: V) {\n return validate<Relationship & V>(v, id, hashRelationship)\n}\n"]}
|
package/dist/predicate.d.ts
CHANGED
|
@@ -9,6 +9,7 @@ export declare const isValidInterestsPref: <T>(v: T) => v is T & AppBskyActorDef
|
|
|
9
9
|
export declare const isValidLabelersPref: <T>(v: T) => v is T & AppBskyActorDefs.LabelersPref;
|
|
10
10
|
export declare const isValidMutedWordsPref: <T>(v: T) => v is T & AppBskyActorDefs.MutedWordsPref;
|
|
11
11
|
export declare const isValidPersonalDetailsPref: <T>(v: T) => v is T & AppBskyActorDefs.PersonalDetailsPref;
|
|
12
|
+
export declare const isValidDeclaredAgePref: <T>(v: T) => v is T & AppBskyActorDefs.DeclaredAgePref;
|
|
12
13
|
export declare const isValidPostInteractionSettingsPref: <T>(v: T) => v is T & AppBskyActorDefs.PostInteractionSettingsPref;
|
|
13
14
|
export declare const isValidSavedFeedsPref: <T>(v: T) => v is T & AppBskyActorDefs.SavedFeedsPref;
|
|
14
15
|
export declare const isValidSavedFeedsPrefV2: <T>(v: T) => v is T & AppBskyActorDefs.SavedFeedsPrefV2;
|
package/dist/predicate.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"predicate.d.ts","sourceRoot":"","sources":["../src/predicate.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,mBAAmB,EAAE,MAAM,gBAAgB,CAAA;AAGtE,eAA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B,uDAEjC,CAAA;AACD,eAAO,MAAM,uBAAuB,yDAEnC,CAAA;AACD,eAAO,MAAM,qBAAqB,uDAEjC,CAAA;AACD,eAAO,MAAM,wBAAwB,0DAEpC,CAAA"}
|
package/dist/predicate.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.isValidVerificationPrefs = exports.isValidThreadViewPref = exports.isValidSavedFeedsPrefV2 = exports.isValidSavedFeedsPref = exports.isValidPostInteractionSettingsPref = exports.isValidPersonalDetailsPref = exports.isValidMutedWordsPref = exports.isValidLabelersPref = exports.isValidInterestsPref = exports.isValidHiddenPostsPref = exports.isValidFeedViewPref = exports.isValidContentLabelPref = exports.isValidBskyAppStatePref = exports.isValidAdultContentPref = exports.isValidProfile = void 0;
|
|
3
|
+
exports.isValidVerificationPrefs = exports.isValidThreadViewPref = exports.isValidSavedFeedsPrefV2 = exports.isValidSavedFeedsPref = exports.isValidPostInteractionSettingsPref = exports.isValidDeclaredAgePref = exports.isValidPersonalDetailsPref = exports.isValidMutedWordsPref = exports.isValidLabelersPref = exports.isValidInterestsPref = exports.isValidHiddenPostsPref = exports.isValidFeedViewPref = exports.isValidContentLabelPref = exports.isValidBskyAppStatePref = exports.isValidAdultContentPref = exports.isValidProfile = void 0;
|
|
4
4
|
const index_1 = require("./client/index");
|
|
5
5
|
const util_1 = require("./client/util");
|
|
6
6
|
exports.isValidProfile = (0, util_1.asPredicate)(index_1.AppBskyActorProfile.validateRecord);
|
|
@@ -13,6 +13,7 @@ exports.isValidInterestsPref = (0, util_1.asPredicate)(index_1.AppBskyActorDefs.
|
|
|
13
13
|
exports.isValidLabelersPref = (0, util_1.asPredicate)(index_1.AppBskyActorDefs.validateLabelersPref);
|
|
14
14
|
exports.isValidMutedWordsPref = (0, util_1.asPredicate)(index_1.AppBskyActorDefs.validateMutedWordsPref);
|
|
15
15
|
exports.isValidPersonalDetailsPref = (0, util_1.asPredicate)(index_1.AppBskyActorDefs.validatePersonalDetailsPref);
|
|
16
|
+
exports.isValidDeclaredAgePref = (0, util_1.asPredicate)(index_1.AppBskyActorDefs.validateDeclaredAgePref);
|
|
16
17
|
exports.isValidPostInteractionSettingsPref = (0, util_1.asPredicate)(index_1.AppBskyActorDefs.validatePostInteractionSettingsPref);
|
|
17
18
|
exports.isValidSavedFeedsPref = (0, util_1.asPredicate)(index_1.AppBskyActorDefs.validateSavedFeedsPref);
|
|
18
19
|
exports.isValidSavedFeedsPrefV2 = (0, util_1.asPredicate)(index_1.AppBskyActorDefs.validateSavedFeedsPrefV2);
|
package/dist/predicate.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"predicate.js","sourceRoot":"","sources":["../src/predicate.ts"],"names":[],"mappings":";;;AAAA,0CAAsE;AACtE,wCAA2C;AAE9B,QAAA,cAAc,GAAG,IAAA,kBAAW,EAAC,2BAAmB,CAAC,cAAc,CAAC,CAAA;AAChE,QAAA,uBAAuB,GAAG,IAAA,kBAAW,EAChD,wBAAgB,CAAC,wBAAwB,CAC1C,CAAA;AACY,QAAA,uBAAuB,GAAG,IAAA,kBAAW,EAChD,wBAAgB,CAAC,wBAAwB,CAC1C,CAAA;AACY,QAAA,uBAAuB,GAAG,IAAA,kBAAW,EAChD,wBAAgB,CAAC,wBAAwB,CAC1C,CAAA;AACY,QAAA,mBAAmB,GAAG,IAAA,kBAAW,EAC5C,wBAAgB,CAAC,oBAAoB,CACtC,CAAA;AACY,QAAA,sBAAsB,GAAG,IAAA,kBAAW,EAC/C,wBAAgB,CAAC,uBAAuB,CACzC,CAAA;AACY,QAAA,oBAAoB,GAAG,IAAA,kBAAW,EAC7C,wBAAgB,CAAC,qBAAqB,CACvC,CAAA;AACY,QAAA,mBAAmB,GAAG,IAAA,kBAAW,EAC5C,wBAAgB,CAAC,oBAAoB,CACtC,CAAA;AACY,QAAA,qBAAqB,GAAG,IAAA,kBAAW,EAC9C,wBAAgB,CAAC,sBAAsB,CACxC,CAAA;AACY,QAAA,0BAA0B,GAAG,IAAA,kBAAW,EACnD,wBAAgB,CAAC,2BAA2B,CAC7C,CAAA;AACY,QAAA,kCAAkC,GAAG,IAAA,kBAAW,EAC3D,wBAAgB,CAAC,mCAAmC,CACrD,CAAA;AACY,QAAA,qBAAqB,GAAG,IAAA,kBAAW,EAC9C,wBAAgB,CAAC,sBAAsB,CACxC,CAAA;AACY,QAAA,uBAAuB,GAAG,IAAA,kBAAW,EAChD,wBAAgB,CAAC,wBAAwB,CAC1C,CAAA;AACY,QAAA,qBAAqB,GAAG,IAAA,kBAAW,EAC9C,wBAAgB,CAAC,sBAAsB,CACxC,CAAA;AACY,QAAA,wBAAwB,GAAG,IAAA,kBAAW,EACjD,wBAAgB,CAAC,yBAAyB,CAC3C,CAAA","sourcesContent":["import { AppBskyActorDefs, AppBskyActorProfile } from './client/index'\nimport { asPredicate } from './client/util'\n\nexport const isValidProfile = asPredicate(AppBskyActorProfile.validateRecord)\nexport const isValidAdultContentPref = asPredicate(\n AppBskyActorDefs.validateAdultContentPref,\n)\nexport const isValidBskyAppStatePref = asPredicate(\n AppBskyActorDefs.validateBskyAppStatePref,\n)\nexport const isValidContentLabelPref = asPredicate(\n AppBskyActorDefs.validateContentLabelPref,\n)\nexport const isValidFeedViewPref = asPredicate(\n AppBskyActorDefs.validateFeedViewPref,\n)\nexport const isValidHiddenPostsPref = asPredicate(\n AppBskyActorDefs.validateHiddenPostsPref,\n)\nexport const isValidInterestsPref = asPredicate(\n AppBskyActorDefs.validateInterestsPref,\n)\nexport const isValidLabelersPref = asPredicate(\n AppBskyActorDefs.validateLabelersPref,\n)\nexport const isValidMutedWordsPref = asPredicate(\n AppBskyActorDefs.validateMutedWordsPref,\n)\nexport const isValidPersonalDetailsPref = asPredicate(\n AppBskyActorDefs.validatePersonalDetailsPref,\n)\nexport const isValidPostInteractionSettingsPref = asPredicate(\n AppBskyActorDefs.validatePostInteractionSettingsPref,\n)\nexport const isValidSavedFeedsPref = asPredicate(\n AppBskyActorDefs.validateSavedFeedsPref,\n)\nexport const isValidSavedFeedsPrefV2 = asPredicate(\n AppBskyActorDefs.validateSavedFeedsPrefV2,\n)\nexport const isValidThreadViewPref = asPredicate(\n AppBskyActorDefs.validateThreadViewPref,\n)\nexport const isValidVerificationPrefs = asPredicate(\n AppBskyActorDefs.validateVerificationPrefs,\n)\n"]}
|
|
1
|
+
{"version":3,"file":"predicate.js","sourceRoot":"","sources":["../src/predicate.ts"],"names":[],"mappings":";;;AAAA,0CAAsE;AACtE,wCAA2C;AAE9B,QAAA,cAAc,GAAG,IAAA,kBAAW,EAAC,2BAAmB,CAAC,cAAc,CAAC,CAAA;AAChE,QAAA,uBAAuB,GAAG,IAAA,kBAAW,EAChD,wBAAgB,CAAC,wBAAwB,CAC1C,CAAA;AACY,QAAA,uBAAuB,GAAG,IAAA,kBAAW,EAChD,wBAAgB,CAAC,wBAAwB,CAC1C,CAAA;AACY,QAAA,uBAAuB,GAAG,IAAA,kBAAW,EAChD,wBAAgB,CAAC,wBAAwB,CAC1C,CAAA;AACY,QAAA,mBAAmB,GAAG,IAAA,kBAAW,EAC5C,wBAAgB,CAAC,oBAAoB,CACtC,CAAA;AACY,QAAA,sBAAsB,GAAG,IAAA,kBAAW,EAC/C,wBAAgB,CAAC,uBAAuB,CACzC,CAAA;AACY,QAAA,oBAAoB,GAAG,IAAA,kBAAW,EAC7C,wBAAgB,CAAC,qBAAqB,CACvC,CAAA;AACY,QAAA,mBAAmB,GAAG,IAAA,kBAAW,EAC5C,wBAAgB,CAAC,oBAAoB,CACtC,CAAA;AACY,QAAA,qBAAqB,GAAG,IAAA,kBAAW,EAC9C,wBAAgB,CAAC,sBAAsB,CACxC,CAAA;AACY,QAAA,0BAA0B,GAAG,IAAA,kBAAW,EACnD,wBAAgB,CAAC,2BAA2B,CAC7C,CAAA;AACY,QAAA,sBAAsB,GAAG,IAAA,kBAAW,EAC/C,wBAAgB,CAAC,uBAAuB,CACzC,CAAA;AACY,QAAA,kCAAkC,GAAG,IAAA,kBAAW,EAC3D,wBAAgB,CAAC,mCAAmC,CACrD,CAAA;AACY,QAAA,qBAAqB,GAAG,IAAA,kBAAW,EAC9C,wBAAgB,CAAC,sBAAsB,CACxC,CAAA;AACY,QAAA,uBAAuB,GAAG,IAAA,kBAAW,EAChD,wBAAgB,CAAC,wBAAwB,CAC1C,CAAA;AACY,QAAA,qBAAqB,GAAG,IAAA,kBAAW,EAC9C,wBAAgB,CAAC,sBAAsB,CACxC,CAAA;AACY,QAAA,wBAAwB,GAAG,IAAA,kBAAW,EACjD,wBAAgB,CAAC,yBAAyB,CAC3C,CAAA","sourcesContent":["import { AppBskyActorDefs, AppBskyActorProfile } from './client/index'\nimport { asPredicate } from './client/util'\n\nexport const isValidProfile = asPredicate(AppBskyActorProfile.validateRecord)\nexport const isValidAdultContentPref = asPredicate(\n AppBskyActorDefs.validateAdultContentPref,\n)\nexport const isValidBskyAppStatePref = asPredicate(\n AppBskyActorDefs.validateBskyAppStatePref,\n)\nexport const isValidContentLabelPref = asPredicate(\n AppBskyActorDefs.validateContentLabelPref,\n)\nexport const isValidFeedViewPref = asPredicate(\n AppBskyActorDefs.validateFeedViewPref,\n)\nexport const isValidHiddenPostsPref = asPredicate(\n AppBskyActorDefs.validateHiddenPostsPref,\n)\nexport const isValidInterestsPref = asPredicate(\n AppBskyActorDefs.validateInterestsPref,\n)\nexport const isValidLabelersPref = asPredicate(\n AppBskyActorDefs.validateLabelersPref,\n)\nexport const isValidMutedWordsPref = asPredicate(\n AppBskyActorDefs.validateMutedWordsPref,\n)\nexport const isValidPersonalDetailsPref = asPredicate(\n AppBskyActorDefs.validatePersonalDetailsPref,\n)\nexport const isValidDeclaredAgePref = asPredicate(\n AppBskyActorDefs.validateDeclaredAgePref,\n)\nexport const isValidPostInteractionSettingsPref = asPredicate(\n AppBskyActorDefs.validatePostInteractionSettingsPref,\n)\nexport const isValidSavedFeedsPref = asPredicate(\n AppBskyActorDefs.validateSavedFeedsPref,\n)\nexport const isValidSavedFeedsPrefV2 = asPredicate(\n AppBskyActorDefs.validateSavedFeedsPrefV2,\n)\nexport const isValidThreadViewPref = asPredicate(\n AppBskyActorDefs.validateThreadViewPref,\n)\nexport const isValidVerificationPrefs = asPredicate(\n AppBskyActorDefs.validateVerificationPrefs,\n)\n"]}
|
package/dist/types.d.ts
CHANGED
|
@@ -89,6 +89,12 @@ export interface BskyPreferences {
|
|
|
89
89
|
threadViewPrefs: BskyThreadViewPreference;
|
|
90
90
|
moderationPrefs: ModerationPrefs;
|
|
91
91
|
birthDate: Date | undefined;
|
|
92
|
+
/**
|
|
93
|
+
* Read-only preference containing value(s) inferred from the user's declared
|
|
94
|
+
* birthdate. Absence of this preference object in the response indicates
|
|
95
|
+
* that the user has not made a declaration.
|
|
96
|
+
*/
|
|
97
|
+
declaredAge?: AppBskyActorDefs.DeclaredAgePref;
|
|
92
98
|
interests: BskyInterestsPreference;
|
|
93
99
|
bskyAppState: {
|
|
94
100
|
queuedNudges: string[];
|
package/dist/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAA;AAC3C,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAA;AAEpD,MAAM,MAAM,kBAAkB,GAAG,MAAM,GAAG,WAAW,CAAC,OAAO,CAAC,CAAA;AAC9D,MAAM,MAAM,kBAAkB,GAAG,iBAAiB,GAAG,kBAAkB,CAAA;AACvE,wBAAgB,oBAAoB,CAAC,CAAC,SAAS,MAAM,EACnD,KAAK,EAAE,CAAC,GACP,KAAK,IAAI,CAAC,GAAG,kBAAkB,CAEjC;AAGD,MAAM,MAAM,GAAG,GAAG,OAAO,MAAM,IAAI,MAAM,EAAE,CAAA;AAC3C,wBAAgB,KAAK,CAAC,CAAC,SAAS,MA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,CAAC","sourcesContent":["import { AppBskyActorDefs } from './client'\nimport { ModerationPrefs } from './moderation/types'\n\nexport type UnknownServiceType = string & NonNullable<unknown>\nexport type AtprotoServiceType = 'atproto_labeler' | UnknownServiceType\nexport function isAtprotoServiceType<T extends string>(\n input: T,\n): input is T & AtprotoServiceType {\n return !input.includes(' ') && !input.includes('#')\n}\n\n// @TODO use tools from @atproto/did\nexport type Did = `did:${string}:${string}`\nexport function isDid<T extends string>(input: T): input is T & Did {\n if (!input.startsWith('did:')) return false\n if (input.length < 8) return false\n if (input.length > 2048) return false\n const msidx = input.indexOf(':', 4)\n return msidx > 4 && msidx < input.length - 1\n}\n\nexport function assertDid(input: string): asserts input is Did {\n if (!isDid(input)) throw new TypeError(`Invalid DID: ${input}`)\n}\n\nexport function asDid<T extends string>(input: T) {\n assertDid(input)\n return input\n}\n\nexport type AtprotoProxy = `${Did}#${AtprotoServiceType}`\nexport function isAtprotoProxy(input: string): input is AtprotoProxy {\n const { length, [0]: did, [1]: service } = input.split('#')\n return length === 2 && isDid(did) && isAtprotoServiceType(service)\n}\n\nexport function assertAtprotoProxy(\n input: string,\n): asserts input is AtprotoProxy {\n if (!isAtprotoProxy(input)) {\n throw new TypeError(\n `Invalid DID reference: ${input} (must be of the form did:example:alice#service)`,\n )\n }\n}\n\nexport function asAtprotoProxy<T extends string>(input: T) {\n assertAtprotoProxy(input)\n return input\n}\n\n/**\n * Used by the PersistSessionHandler to indicate what change occurred\n */\nexport type AtpSessionEvent =\n | 'create'\n | 'create-failed'\n | 'update'\n | 'expired'\n | 'network-error'\n\n/**\n * Used by AtpAgent to store active sessions\n */\nexport interface AtpSessionData {\n refreshJwt: string\n accessJwt: string\n handle: string\n did: string\n email?: string\n emailConfirmed?: boolean\n emailAuthFactor?: boolean\n active: boolean\n status?: string\n}\n\n/**\n * Handler signature passed to AtpAgent to store session data\n */\nexport type AtpPersistSessionHandler = (\n evt: AtpSessionEvent,\n session: AtpSessionData | undefined,\n) => void | Promise<void>\n\n/**\n * AtpAgent login() opts\n */\nexport interface AtpAgentLoginOpts {\n identifier: string\n password: string\n authFactorToken?: string | undefined\n allowTakendown?: boolean\n}\n\n/**\n * AtpAgent global config opts\n */\nexport interface AtpAgentGlobalOpts {\n appLabelers?: string[]\n}\n\n/**\n * Bluesky feed view preferences\n */\n\nexport interface BskyFeedViewPreference {\n hideReplies: boolean\n hideRepliesByUnfollowed: boolean\n hideRepliesByLikeCount: number\n hideReposts: boolean\n hideQuotePosts: boolean\n [key: string]: any\n}\n\n/**\n * Bluesky thread view preferences\n */\nexport interface BskyThreadViewPreference {\n sort: string\n [key: string]: any\n}\n\n/**\n * Bluesky interests preferences\n */\nexport interface BskyInterestsPreference {\n tags: string[]\n [key: string]: any\n}\n\n/**\n * Bluesky preferences\n */\nexport interface BskyPreferences {\n /**\n * @deprecated use `savedFeeds`\n */\n feeds: {\n saved?: string[]\n pinned?: string[]\n }\n savedFeeds: AppBskyActorDefs.SavedFeed[]\n feedViewPrefs: Record<string, BskyFeedViewPreference>\n threadViewPrefs: BskyThreadViewPreference\n moderationPrefs: ModerationPrefs\n birthDate: Date | undefined\n interests: BskyInterestsPreference\n bskyAppState: {\n queuedNudges: string[]\n activeProgressGuide: AppBskyActorDefs.BskyAppProgressGuide | undefined\n nuxs: AppBskyActorDefs.Nux[]\n }\n postInteractionSettings: AppBskyActorDefs.PostInteractionSettingsPref\n verificationPrefs: AppBskyActorDefs.VerificationPrefs\n}\n"]}
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":";;AAKA,oDAIC;AAID,sBAMC;AAED,8BAEC;AAED,sBAGC;AAGD,wCAGC;AAED,gDAQC;AAED,wCAGC;AA5CD,SAAgB,oBAAoB,CAClC,KAAQ;IAER,OAAO,CAAC,KAAK,CAAC,QAAQ,CAAC,GAAG,CAAC,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAA;AACrD,CAAC;AAID,SAAgB,KA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","sourcesContent":["import { AppBskyActorDefs } from './client'\nimport { ModerationPrefs } from './moderation/types'\n\nexport type UnknownServiceType = string & NonNullable<unknown>\nexport type AtprotoServiceType = 'atproto_labeler' | UnknownServiceType\nexport function isAtprotoServiceType<T extends string>(\n input: T,\n): input is T & AtprotoServiceType {\n return !input.includes(' ') && !input.includes('#')\n}\n\n// @TODO use tools from @atproto/did\nexport type Did = `did:${string}:${string}`\nexport function isDid<T extends string>(input: T): input is T & Did {\n if (!input.startsWith('did:')) return false\n if (input.length < 8) return false\n if (input.length > 2048) return false\n const msidx = input.indexOf(':', 4)\n return msidx > 4 && msidx < input.length - 1\n}\n\nexport function assertDid(input: string): asserts input is Did {\n if (!isDid(input)) throw new TypeError(`Invalid DID: ${input}`)\n}\n\nexport function asDid<T extends string>(input: T) {\n assertDid(input)\n return input\n}\n\nexport type AtprotoProxy = `${Did}#${AtprotoServiceType}`\nexport function isAtprotoProxy(input: string): input is AtprotoProxy {\n const { length, [0]: did, [1]: service } = input.split('#')\n return length === 2 && isDid(did) && isAtprotoServiceType(service)\n}\n\nexport function assertAtprotoProxy(\n input: string,\n): asserts input is AtprotoProxy {\n if (!isAtprotoProxy(input)) {\n throw new TypeError(\n `Invalid DID reference: ${input} (must be of the form did:example:alice#service)`,\n )\n }\n}\n\nexport function asAtprotoProxy<T extends string>(input: T) {\n assertAtprotoProxy(input)\n return input\n}\n\n/**\n * Used by the PersistSessionHandler to indicate what change occurred\n */\nexport type AtpSessionEvent =\n | 'create'\n | 'create-failed'\n | 'update'\n | 'expired'\n | 'network-error'\n\n/**\n * Used by AtpAgent to store active sessions\n */\nexport interface AtpSessionData {\n refreshJwt: string\n accessJwt: string\n handle: string\n did: string\n email?: string\n emailConfirmed?: boolean\n emailAuthFactor?: boolean\n active: boolean\n status?: string\n}\n\n/**\n * Handler signature passed to AtpAgent to store session data\n */\nexport type AtpPersistSessionHandler = (\n evt: AtpSessionEvent,\n session: AtpSessionData | undefined,\n) => void | Promise<void>\n\n/**\n * AtpAgent login() opts\n */\nexport interface AtpAgentLoginOpts {\n identifier: string\n password: string\n authFactorToken?: string | undefined\n allowTakendown?: boolean\n}\n\n/**\n * AtpAgent global config opts\n */\nexport interface AtpAgentGlobalOpts {\n appLabelers?: string[]\n}\n\n/**\n * Bluesky feed view preferences\n */\n\nexport interface BskyFeedViewPreference {\n hideReplies: boolean\n hideRepliesByUnfollowed: boolean\n hideRepliesByLikeCount: number\n hideReposts: boolean\n hideQuotePosts: boolean\n [key: string]: any\n}\n\n/**\n * Bluesky thread view preferences\n */\nexport interface BskyThreadViewPreference {\n sort: string\n [key: string]: any\n}\n\n/**\n * Bluesky interests preferences\n */\nexport interface BskyInterestsPreference {\n tags: string[]\n [key: string]: any\n}\n\n/**\n * Bluesky preferences\n */\nexport interface BskyPreferences {\n /**\n * @deprecated use `savedFeeds`\n */\n feeds: {\n saved?: string[]\n pinned?: string[]\n }\n savedFeeds: AppBskyActorDefs.SavedFeed[]\n feedViewPrefs: Record<string, BskyFeedViewPreference>\n threadViewPrefs: BskyThreadViewPreference\n moderationPrefs: ModerationPrefs\n birthDate: Date | undefined\n /**\n * Read-only preference containing value(s) inferred from the user's declared\n * birthdate. Absence of this preference object in the response indicates\n * that the user has not made a declaration.\n */\n declaredAge?: AppBskyActorDefs.DeclaredAgePref\n interests: BskyInterestsPreference\n bskyAppState: {\n queuedNudges: string[]\n activeProgressGuide: AppBskyActorDefs.BskyAppProgressGuide | undefined\n nuxs: AppBskyActorDefs.Nux[]\n }\n postInteractionSettings: AppBskyActorDefs.PostInteractionSettingsPref\n verificationPrefs: AppBskyActorDefs.VerificationPrefs\n}\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atproto/api",
|
|
3
|
-
"version": "0.18.
|
|
3
|
+
"version": "0.18.6",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "Client library for atproto and Bluesky",
|
|
6
6
|
"keywords": [
|
|
@@ -21,17 +21,17 @@
|
|
|
21
21
|
"multiformats": "^9.9.0",
|
|
22
22
|
"tlds": "^1.234.0",
|
|
23
23
|
"zod": "^3.23.8",
|
|
24
|
-
"@atproto/common-web": "^0.4.
|
|
25
|
-
"@atproto/lexicon": "^0.
|
|
24
|
+
"@atproto/common-web": "^0.4.7",
|
|
25
|
+
"@atproto/lexicon": "^0.6.0",
|
|
26
26
|
"@atproto/syntax": "^0.4.2",
|
|
27
|
-
"@atproto/xrpc": "^0.7.
|
|
27
|
+
"@atproto/xrpc": "^0.7.7"
|
|
28
28
|
},
|
|
29
29
|
"devDependencies": {
|
|
30
30
|
"@jest/globals": "^28.1.3",
|
|
31
31
|
"jest": "^28.1.2",
|
|
32
32
|
"prettier": "^3.2.5",
|
|
33
33
|
"typescript": "^5.6.3",
|
|
34
|
-
"@atproto/lex-cli": "^0.9.
|
|
34
|
+
"@atproto/lex-cli": "^0.9.8"
|
|
35
35
|
},
|
|
36
36
|
"scripts": {
|
|
37
37
|
"codegen": "node ./scripts/generate-code.mjs && lex gen-api --yes ./src/client ../../lexicons/com/atproto/*/* ../../lexicons/app/bsky/*/* ../../lexicons/chat/bsky/*/* ../../lexicons/tools/ozone/*/*",
|
package/src/agent.ts
CHANGED
|
@@ -619,6 +619,9 @@ export class Agent extends XrpcClient {
|
|
|
619
619
|
if (pref.birthDate) {
|
|
620
620
|
prefs.birthDate = new Date(pref.birthDate)
|
|
621
621
|
}
|
|
622
|
+
} else if (predicate.isValidDeclaredAgePref(pref)) {
|
|
623
|
+
const { $type: _, ...declaredAgePref } = pref
|
|
624
|
+
prefs.declaredAge = declaredAgePref
|
|
622
625
|
} else if (predicate.isValidFeedViewPref(pref)) {
|
|
623
626
|
// feed view preferences
|
|
624
627
|
const { $type: _, feed, ...v } = pref
|