@atproto/bsky 0.0.202 → 0.0.203

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.
Files changed (80) hide show
  1. package/CHANGELOG.md +6 -0
  2. package/dist/api/age-assurance/const.d.ts.map +1 -1
  3. package/dist/api/age-assurance/const.js +20 -0
  4. package/dist/api/age-assurance/const.js.map +1 -1
  5. package/dist/api/app/bsky/contact/dismissMatch.d.ts.map +1 -1
  6. package/dist/api/app/bsky/contact/dismissMatch.js +2 -3
  7. package/dist/api/app/bsky/contact/dismissMatch.js.map +1 -1
  8. package/dist/api/app/bsky/contact/getMatches.js +2 -3
  9. package/dist/api/app/bsky/contact/getMatches.js.map +1 -1
  10. package/dist/api/app/bsky/contact/getSyncStatus.d.ts.map +1 -1
  11. package/dist/api/app/bsky/contact/getSyncStatus.js +2 -3
  12. package/dist/api/app/bsky/contact/getSyncStatus.js.map +1 -1
  13. package/dist/api/app/bsky/contact/importContacts.js +2 -3
  14. package/dist/api/app/bsky/contact/importContacts.js.map +1 -1
  15. package/dist/api/app/bsky/contact/removeData.d.ts.map +1 -1
  16. package/dist/api/app/bsky/contact/removeData.js +2 -3
  17. package/dist/api/app/bsky/contact/removeData.js.map +1 -1
  18. package/dist/api/app/bsky/contact/sendNotification.d.ts.map +1 -1
  19. package/dist/api/app/bsky/contact/sendNotification.js.map +1 -1
  20. package/dist/api/app/bsky/contact/startPhoneVerification.d.ts.map +1 -1
  21. package/dist/api/app/bsky/contact/startPhoneVerification.js +2 -3
  22. package/dist/api/app/bsky/contact/startPhoneVerification.js.map +1 -1
  23. package/dist/api/app/bsky/contact/util.d.ts +7 -0
  24. package/dist/api/app/bsky/contact/util.d.ts.map +1 -1
  25. package/dist/api/app/bsky/contact/util.js +68 -0
  26. package/dist/api/app/bsky/contact/util.js.map +1 -1
  27. package/dist/api/app/bsky/contact/verifyPhone.d.ts.map +1 -1
  28. package/dist/api/app/bsky/contact/verifyPhone.js +2 -3
  29. package/dist/api/app/bsky/contact/verifyPhone.js.map +1 -1
  30. package/dist/api/index.d.ts.map +1 -1
  31. package/dist/api/index.js +2 -0
  32. package/dist/api/index.js.map +1 -1
  33. package/dist/hydration/actor.js +1 -1
  34. package/dist/hydration/actor.js.map +1 -1
  35. package/dist/lexicon/lexicons.d.ts +98 -44
  36. package/dist/lexicon/lexicons.d.ts.map +1 -1
  37. package/dist/lexicon/lexicons.js +66 -22
  38. package/dist/lexicon/lexicons.js.map +1 -1
  39. package/dist/lexicon/types/app/bsky/contact/dismissMatch.d.ts +1 -1
  40. package/dist/lexicon/types/app/bsky/contact/dismissMatch.d.ts.map +1 -1
  41. package/dist/lexicon/types/app/bsky/contact/dismissMatch.js.map +1 -1
  42. package/dist/lexicon/types/app/bsky/contact/getMatches.d.ts +1 -1
  43. package/dist/lexicon/types/app/bsky/contact/getMatches.d.ts.map +1 -1
  44. package/dist/lexicon/types/app/bsky/contact/getMatches.js.map +1 -1
  45. package/dist/lexicon/types/app/bsky/contact/getSyncStatus.d.ts +1 -1
  46. package/dist/lexicon/types/app/bsky/contact/getSyncStatus.d.ts.map +1 -1
  47. package/dist/lexicon/types/app/bsky/contact/getSyncStatus.js.map +1 -1
  48. package/dist/lexicon/types/app/bsky/contact/importContacts.d.ts +1 -1
  49. package/dist/lexicon/types/app/bsky/contact/importContacts.d.ts.map +1 -1
  50. package/dist/lexicon/types/app/bsky/contact/importContacts.js.map +1 -1
  51. package/dist/lexicon/types/app/bsky/contact/removeData.d.ts +1 -1
  52. package/dist/lexicon/types/app/bsky/contact/removeData.d.ts.map +1 -1
  53. package/dist/lexicon/types/app/bsky/contact/removeData.js.map +1 -1
  54. package/dist/lexicon/types/app/bsky/contact/startPhoneVerification.d.ts +1 -1
  55. package/dist/lexicon/types/app/bsky/contact/startPhoneVerification.d.ts.map +1 -1
  56. package/dist/lexicon/types/app/bsky/contact/startPhoneVerification.js.map +1 -1
  57. package/dist/lexicon/types/app/bsky/contact/verifyPhone.d.ts +1 -1
  58. package/dist/lexicon/types/app/bsky/contact/verifyPhone.d.ts.map +1 -1
  59. package/dist/lexicon/types/app/bsky/contact/verifyPhone.js.map +1 -1
  60. package/package.json +8 -8
  61. package/src/api/age-assurance/const.ts +20 -0
  62. package/src/api/app/bsky/contact/dismissMatch.ts +7 -6
  63. package/src/api/app/bsky/contact/getMatches.ts +8 -7
  64. package/src/api/app/bsky/contact/getSyncStatus.ts +6 -5
  65. package/src/api/app/bsky/contact/importContacts.ts +8 -7
  66. package/src/api/app/bsky/contact/removeData.ts +6 -5
  67. package/src/api/app/bsky/contact/sendNotification.ts +2 -1
  68. package/src/api/app/bsky/contact/startPhoneVerification.ts +7 -6
  69. package/src/api/app/bsky/contact/util.ts +80 -1
  70. package/src/api/app/bsky/contact/verifyPhone.ts +8 -7
  71. package/src/api/index.ts +2 -0
  72. package/src/hydration/actor.ts +1 -1
  73. package/src/lexicon/lexicons.ts +66 -22
  74. package/src/lexicon/types/app/bsky/contact/dismissMatch.ts +1 -1
  75. package/src/lexicon/types/app/bsky/contact/getMatches.ts +1 -1
  76. package/src/lexicon/types/app/bsky/contact/getSyncStatus.ts +1 -1
  77. package/src/lexicon/types/app/bsky/contact/importContacts.ts +6 -1
  78. package/src/lexicon/types/app/bsky/contact/removeData.ts +1 -1
  79. package/src/lexicon/types/app/bsky/contact/startPhoneVerification.ts +1 -1
  80. package/src/lexicon/types/app/bsky/contact/verifyPhone.ts +6 -1
@@ -19,7 +19,7 @@ export interface HandlerSuccess {
19
19
  export interface HandlerError {
20
20
  status: number;
21
21
  message?: string;
22
- error?: 'TODO';
22
+ error?: 'InvalidDid' | 'InternalError';
23
23
  }
24
24
  export type HandlerOutput = HandlerError | HandlerSuccess;
25
25
  //# sourceMappingURL=dismissMatch.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"dismissMatch.d.ts","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/dismissMatch.ts"],"names":[],"mappings":"AAgBA,MAAM,MAAM,WAAW,GAAG,EAAE,CAAA;AAE5B,MAAM,WAAW,WAAW;IAC1B,mDAAmD;IACnD,OAAO,EAAE,MAAM,CAAA;CAChB;AAED,MAAM,WAAW,YAAY;CAAG;AAEhC,MAAM,WAAW,YAAY;IAC3B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,WAAW,CAAA;CAClB;AAED,MAAM,WAAW,cAAc;IAC7B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,YAAY,CAAA;IAClB,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAA;CACpC;AAED,MAAM,WAAW,YAAY;IAC3B,MAAM,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,KAAK,CAAC,EAAE,MAAM,CAAA;CACf;AAED,MAAM,MAAM,aAAa,GAAG,YAAY,GAAG,cAAc,CAAA"}
1
+ {"version":3,"file":"dismissMatch.d.ts","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/dismissMatch.ts"],"names":[],"mappings":"AAgBA,MAAM,MAAM,WAAW,GAAG,EAAE,CAAA;AAE5B,MAAM,WAAW,WAAW;IAC1B,mDAAmD;IACnD,OAAO,EAAE,MAAM,CAAA;CAChB;AAED,MAAM,WAAW,YAAY;CAAG;AAEhC,MAAM,WAAW,YAAY;IAC3B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,WAAW,CAAA;CAClB;AAED,MAAM,WAAW,cAAc;IAC7B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,YAAY,CAAA;IAClB,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAA;CACpC;AAED,MAAM,WAAW,YAAY;IAC3B,MAAM,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,KAAK,CAAC,EAAE,YAAY,GAAG,eAAe,CAAA;CACvC;AAED,MAAM,MAAM,aAAa,GAAG,YAAY,GAAG,cAAc,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"dismissMatch.js","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/dismissMatch.ts"],"names":[],"mappings":";;AAKA,mDAA4D;AAC5D,2CAIyB;AAEzB,MAAM,QAAQ,GAAG,eAAS,EACxB,QAAQ,GAAG,mBAAS,CAAA;AACtB,MAAM,EAAE,GAAG,+BAA+B,CAAA","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'\n\nconst is$typed = _is$typed,\n validate = _validate\nconst id = 'app.bsky.contact.dismissMatch'\n\nexport type QueryParams = {}\n\nexport interface InputSchema {\n /** The subject's DID to dismiss the match with. */\n subject: string\n}\n\nexport interface OutputSchema {}\n\nexport interface HandlerInput {\n encoding: 'application/json'\n body: InputSchema\n}\n\nexport interface HandlerSuccess {\n encoding: 'application/json'\n body: OutputSchema\n headers?: { [key: string]: string }\n}\n\nexport interface HandlerError {\n status: number\n message?: string\n error?: 'TODO'\n}\n\nexport type HandlerOutput = HandlerError | HandlerSuccess\n"]}
1
+ {"version":3,"file":"dismissMatch.js","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/dismissMatch.ts"],"names":[],"mappings":";;AAKA,mDAA4D;AAC5D,2CAIyB;AAEzB,MAAM,QAAQ,GAAG,eAAS,EACxB,QAAQ,GAAG,mBAAS,CAAA;AACtB,MAAM,EAAE,GAAG,+BAA+B,CAAA","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'\n\nconst is$typed = _is$typed,\n validate = _validate\nconst id = 'app.bsky.contact.dismissMatch'\n\nexport type QueryParams = {}\n\nexport interface InputSchema {\n /** The subject's DID to dismiss the match with. */\n subject: string\n}\n\nexport interface OutputSchema {}\n\nexport interface HandlerInput {\n encoding: 'application/json'\n body: InputSchema\n}\n\nexport interface HandlerSuccess {\n encoding: 'application/json'\n body: OutputSchema\n headers?: { [key: string]: string }\n}\n\nexport interface HandlerError {\n status: number\n message?: string\n error?: 'InvalidDid' | 'InternalError'\n}\n\nexport type HandlerOutput = HandlerError | HandlerSuccess\n"]}
@@ -19,7 +19,7 @@ export interface HandlerSuccess {
19
19
  export interface HandlerError {
20
20
  status: number;
21
21
  message?: string;
22
- error?: 'TODO';
22
+ error?: 'InvalidDid' | 'InvalidLimit' | 'InvalidCursor' | 'InternalError';
23
23
  }
24
24
  export type HandlerOutput = HandlerError | HandlerSuccess;
25
25
  //# sourceMappingURL=getMatches.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"getMatches.d.ts","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/getMatches.ts"],"names":[],"mappings":"AAWA,OAAO,KAAK,KAAK,gBAAgB,MAAM,kBAAkB,CAAA;AAMzD,MAAM,MAAM,WAAW,GAAG;IACxB,KAAK,EAAE,MAAM,CAAA;IACb,MAAM,CAAC,EAAE,MAAM,CAAA;CAChB,CAAA;AACD,MAAM,MAAM,WAAW,GAAG,SAAS,CAAA;AAEnC,MAAM,WAAW,YAAY;IAC3B,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,OAAO,EAAE,gBAAgB,CAAC,WAAW,EAAE,CAAA;CACxC;AAED,MAAM,MAAM,YAAY,GAAG,IAAI,CAAA;AAE/B,MAAM,WAAW,cAAc;IAC7B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,YAAY,CAAA;IAClB,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAA;CACpC;AAED,MAAM,WAAW,YAAY;IAC3B,MAAM,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,KAAK,CAAC,EAAE,MAAM,CAAA;CACf;AAED,MAAM,MAAM,aAAa,GAAG,YAAY,GAAG,cAAc,CAAA"}
1
+ {"version":3,"file":"getMatches.d.ts","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/getMatches.ts"],"names":[],"mappings":"AAWA,OAAO,KAAK,KAAK,gBAAgB,MAAM,kBAAkB,CAAA;AAMzD,MAAM,MAAM,WAAW,GAAG;IACxB,KAAK,EAAE,MAAM,CAAA;IACb,MAAM,CAAC,EAAE,MAAM,CAAA;CAChB,CAAA;AACD,MAAM,MAAM,WAAW,GAAG,SAAS,CAAA;AAEnC,MAAM,WAAW,YAAY;IAC3B,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,OAAO,EAAE,gBAAgB,CAAC,WAAW,EAAE,CAAA;CACxC;AAED,MAAM,MAAM,YAAY,GAAG,IAAI,CAAA;AAE/B,MAAM,WAAW,cAAc;IAC7B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,YAAY,CAAA;IAClB,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAA;CACpC;AAED,MAAM,WAAW,YAAY;IAC3B,MAAM,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,KAAK,CAAC,EAAE,YAAY,GAAG,cAAc,GAAG,eAAe,GAAG,eAAe,CAAA;CAC1E;AAED,MAAM,MAAM,aAAa,GAAG,YAAY,GAAG,cAAc,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"getMatches.js","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/getMatches.ts"],"names":[],"mappings":";;AAKA,mDAA4D;AAC5D,2CAIyB;AAGzB,MAAM,QAAQ,GAAG,eAAS,EACxB,QAAQ,GAAG,mBAAS,CAAA;AACtB,MAAM,EAAE,GAAG,6BAA6B,CAAA","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 AppBskyActorDefs from '../actor/defs.js'\n\nconst is$typed = _is$typed,\n validate = _validate\nconst id = 'app.bsky.contact.getMatches'\n\nexport type QueryParams = {\n limit: number\n cursor?: string\n}\nexport type InputSchema = undefined\n\nexport interface OutputSchema {\n cursor?: string\n matches: AppBskyActorDefs.ProfileView[]\n}\n\nexport type HandlerInput = void\n\nexport interface HandlerSuccess {\n encoding: 'application/json'\n body: OutputSchema\n headers?: { [key: string]: string }\n}\n\nexport interface HandlerError {\n status: number\n message?: string\n error?: 'TODO'\n}\n\nexport type HandlerOutput = HandlerError | HandlerSuccess\n"]}
1
+ {"version":3,"file":"getMatches.js","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/getMatches.ts"],"names":[],"mappings":";;AAKA,mDAA4D;AAC5D,2CAIyB;AAGzB,MAAM,QAAQ,GAAG,eAAS,EACxB,QAAQ,GAAG,mBAAS,CAAA;AACtB,MAAM,EAAE,GAAG,6BAA6B,CAAA","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 AppBskyActorDefs from '../actor/defs.js'\n\nconst is$typed = _is$typed,\n validate = _validate\nconst id = 'app.bsky.contact.getMatches'\n\nexport type QueryParams = {\n limit: number\n cursor?: string\n}\nexport type InputSchema = undefined\n\nexport interface OutputSchema {\n cursor?: string\n matches: AppBskyActorDefs.ProfileView[]\n}\n\nexport type HandlerInput = void\n\nexport interface HandlerSuccess {\n encoding: 'application/json'\n body: OutputSchema\n headers?: { [key: string]: string }\n}\n\nexport interface HandlerError {\n status: number\n message?: string\n error?: 'InvalidDid' | 'InvalidLimit' | 'InvalidCursor' | 'InternalError'\n}\n\nexport type HandlerOutput = HandlerError | HandlerSuccess\n"]}
@@ -15,7 +15,7 @@ export interface HandlerSuccess {
15
15
  export interface HandlerError {
16
16
  status: number;
17
17
  message?: string;
18
- error?: 'TODO';
18
+ error?: 'InvalidDid' | 'InternalError';
19
19
  }
20
20
  export type HandlerOutput = HandlerError | HandlerSuccess;
21
21
  //# sourceMappingURL=getSyncStatus.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"getSyncStatus.d.ts","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/getSyncStatus.ts"],"names":[],"mappings":"AAWA,OAAO,KAAK,KAAK,kBAAkB,MAAM,WAAW,CAAA;AAMpD,MAAM,MAAM,WAAW,GAAG,EAAE,CAAA;AAC5B,MAAM,MAAM,WAAW,GAAG,SAAS,CAAA;AAEnC,MAAM,WAAW,YAAY;IAC3B,UAAU,CAAC,EAAE,kBAAkB,CAAC,UAAU,CAAA;CAC3C;AAED,MAAM,MAAM,YAAY,GAAG,IAAI,CAAA;AAE/B,MAAM,WAAW,cAAc;IAC7B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,YAAY,CAAA;IAClB,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAA;CACpC;AAED,MAAM,WAAW,YAAY;IAC3B,MAAM,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,KAAK,CAAC,EAAE,MAAM,CAAA;CACf;AAED,MAAM,MAAM,aAAa,GAAG,YAAY,GAAG,cAAc,CAAA"}
1
+ {"version":3,"file":"getSyncStatus.d.ts","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/getSyncStatus.ts"],"names":[],"mappings":"AAWA,OAAO,KAAK,KAAK,kBAAkB,MAAM,WAAW,CAAA;AAMpD,MAAM,MAAM,WAAW,GAAG,EAAE,CAAA;AAC5B,MAAM,MAAM,WAAW,GAAG,SAAS,CAAA;AAEnC,MAAM,WAAW,YAAY;IAC3B,UAAU,CAAC,EAAE,kBAAkB,CAAC,UAAU,CAAA;CAC3C;AAED,MAAM,MAAM,YAAY,GAAG,IAAI,CAAA;AAE/B,MAAM,WAAW,cAAc;IAC7B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,YAAY,CAAA;IAClB,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAA;CACpC;AAED,MAAM,WAAW,YAAY;IAC3B,MAAM,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,KAAK,CAAC,EAAE,YAAY,GAAG,eAAe,CAAA;CACvC;AAED,MAAM,MAAM,aAAa,GAAG,YAAY,GAAG,cAAc,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"getSyncStatus.js","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/getSyncStatus.ts"],"names":[],"mappings":";;AAKA,mDAA4D;AAC5D,2CAIyB;AAGzB,MAAM,QAAQ,GAAG,eAAS,EACxB,QAAQ,GAAG,mBAAS,CAAA;AACtB,MAAM,EAAE,GAAG,gCAAgC,CAAA","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 AppBskyContactDefs from './defs.js'\n\nconst is$typed = _is$typed,\n validate = _validate\nconst id = 'app.bsky.contact.getSyncStatus'\n\nexport type QueryParams = {}\nexport type InputSchema = undefined\n\nexport interface OutputSchema {\n syncStatus?: AppBskyContactDefs.SyncStatus\n}\n\nexport type HandlerInput = void\n\nexport interface HandlerSuccess {\n encoding: 'application/json'\n body: OutputSchema\n headers?: { [key: string]: string }\n}\n\nexport interface HandlerError {\n status: number\n message?: string\n error?: 'TODO'\n}\n\nexport type HandlerOutput = HandlerError | HandlerSuccess\n"]}
1
+ {"version":3,"file":"getSyncStatus.js","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/getSyncStatus.ts"],"names":[],"mappings":";;AAKA,mDAA4D;AAC5D,2CAIyB;AAGzB,MAAM,QAAQ,GAAG,eAAS,EACxB,QAAQ,GAAG,mBAAS,CAAA;AACtB,MAAM,EAAE,GAAG,gCAAgC,CAAA","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 AppBskyContactDefs from './defs.js'\n\nconst is$typed = _is$typed,\n validate = _validate\nconst id = 'app.bsky.contact.getSyncStatus'\n\nexport type QueryParams = {}\nexport type InputSchema = undefined\n\nexport interface OutputSchema {\n syncStatus?: AppBskyContactDefs.SyncStatus\n}\n\nexport type HandlerInput = void\n\nexport interface HandlerSuccess {\n encoding: 'application/json'\n body: OutputSchema\n headers?: { [key: string]: string }\n}\n\nexport interface HandlerError {\n status: number\n message?: string\n error?: 'InvalidDid' | 'InternalError'\n}\n\nexport type HandlerOutput = HandlerError | HandlerSuccess\n"]}
@@ -24,7 +24,7 @@ export interface HandlerSuccess {
24
24
  export interface HandlerError {
25
25
  status: number;
26
26
  message?: string;
27
- error?: 'TODO';
27
+ error?: 'InvalidDid' | 'InvalidContacts' | 'TooManyContacts' | 'InvalidToken' | 'InternalError';
28
28
  }
29
29
  export type HandlerOutput = HandlerError | HandlerSuccess;
30
30
  //# sourceMappingURL=importContacts.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"importContacts.d.ts","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/importContacts.ts"],"names":[],"mappings":"AAWA,OAAO,KAAK,KAAK,kBAAkB,MAAM,WAAW,CAAA;AAMpD,MAAM,MAAM,WAAW,GAAG,EAAE,CAAA;AAE5B,MAAM,WAAW,WAAW;IAC1B,sHAAsH;IACtH,KAAK,EAAE,MAAM,CAAA;IACb,4OAA4O;IAC5O,QAAQ,EAAE,MAAM,EAAE,CAAA;CACnB;AAED,MAAM,WAAW,YAAY;IAC3B,qIAAqI;IACrI,wBAAwB,EAAE,kBAAkB,CAAC,oBAAoB,EAAE,CAAA;CACpE;AAED,MAAM,WAAW,YAAY;IAC3B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,WAAW,CAAA;CAClB;AAED,MAAM,WAAW,cAAc;IAC7B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,YAAY,CAAA;IAClB,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAA;CACpC;AAED,MAAM,WAAW,YAAY;IAC3B,MAAM,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,KAAK,CAAC,EAAE,MAAM,CAAA;CACf;AAED,MAAM,MAAM,aAAa,GAAG,YAAY,GAAG,cAAc,CAAA"}
1
+ {"version":3,"file":"importContacts.d.ts","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/importContacts.ts"],"names":[],"mappings":"AAWA,OAAO,KAAK,KAAK,kBAAkB,MAAM,WAAW,CAAA;AAMpD,MAAM,MAAM,WAAW,GAAG,EAAE,CAAA;AAE5B,MAAM,WAAW,WAAW;IAC1B,sHAAsH;IACtH,KAAK,EAAE,MAAM,CAAA;IACb,4OAA4O;IAC5O,QAAQ,EAAE,MAAM,EAAE,CAAA;CACnB;AAED,MAAM,WAAW,YAAY;IAC3B,qIAAqI;IACrI,wBAAwB,EAAE,kBAAkB,CAAC,oBAAoB,EAAE,CAAA;CACpE;AAED,MAAM,WAAW,YAAY;IAC3B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,WAAW,CAAA;CAClB;AAED,MAAM,WAAW,cAAc;IAC7B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,YAAY,CAAA;IAClB,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAA;CACpC;AAED,MAAM,WAAW,YAAY;IAC3B,MAAM,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,KAAK,CAAC,EACF,YAAY,GACZ,iBAAiB,GACjB,iBAAiB,GACjB,cAAc,GACd,eAAe,CAAA;CACpB;AAED,MAAM,MAAM,aAAa,GAAG,YAAY,GAAG,cAAc,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"importContacts.js","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/importContacts.ts"],"names":[],"mappings":";;AAKA,mDAA4D;AAC5D,2CAIyB;AAGzB,MAAM,QAAQ,GAAG,eAAS,EACxB,QAAQ,GAAG,mBAAS,CAAA;AACtB,MAAM,EAAE,GAAG,iCAAiC,CAAA","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 AppBskyContactDefs from './defs.js'\n\nconst is$typed = _is$typed,\n validate = _validate\nconst id = 'app.bsky.contact.importContacts'\n\nexport type QueryParams = {}\n\nexport interface InputSchema {\n /** JWT to authenticate the call. Use the JWT received as a response to the call to `app.bsky.contact.verifyPhone`. */\n token: string\n /** List of phone numbers in global E.164 format (e.g., '+12125550123'). Phone numbers that cannot be normalized into a valid phone number will be discarded. Should not repeat the 'phone' input used in `app.bsky.contact.verifyPhone`. */\n contacts: string[]\n}\n\nexport interface OutputSchema {\n /** The users that matched during import and their indexes on the input contacts, so the client can correlate with its local list. */\n matchesAndContactIndexes: AppBskyContactDefs.MatchAndContactIndex[]\n}\n\nexport interface HandlerInput {\n encoding: 'application/json'\n body: InputSchema\n}\n\nexport interface HandlerSuccess {\n encoding: 'application/json'\n body: OutputSchema\n headers?: { [key: string]: string }\n}\n\nexport interface HandlerError {\n status: number\n message?: string\n error?: 'TODO'\n}\n\nexport type HandlerOutput = HandlerError | HandlerSuccess\n"]}
1
+ {"version":3,"file":"importContacts.js","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/importContacts.ts"],"names":[],"mappings":";;AAKA,mDAA4D;AAC5D,2CAIyB;AAGzB,MAAM,QAAQ,GAAG,eAAS,EACxB,QAAQ,GAAG,mBAAS,CAAA;AACtB,MAAM,EAAE,GAAG,iCAAiC,CAAA","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 AppBskyContactDefs from './defs.js'\n\nconst is$typed = _is$typed,\n validate = _validate\nconst id = 'app.bsky.contact.importContacts'\n\nexport type QueryParams = {}\n\nexport interface InputSchema {\n /** JWT to authenticate the call. Use the JWT received as a response to the call to `app.bsky.contact.verifyPhone`. */\n token: string\n /** List of phone numbers in global E.164 format (e.g., '+12125550123'). Phone numbers that cannot be normalized into a valid phone number will be discarded. Should not repeat the 'phone' input used in `app.bsky.contact.verifyPhone`. */\n contacts: string[]\n}\n\nexport interface OutputSchema {\n /** The users that matched during import and their indexes on the input contacts, so the client can correlate with its local list. */\n matchesAndContactIndexes: AppBskyContactDefs.MatchAndContactIndex[]\n}\n\nexport interface HandlerInput {\n encoding: 'application/json'\n body: InputSchema\n}\n\nexport interface HandlerSuccess {\n encoding: 'application/json'\n body: OutputSchema\n headers?: { [key: string]: string }\n}\n\nexport interface HandlerError {\n status: number\n message?: string\n error?:\n | 'InvalidDid'\n | 'InvalidContacts'\n | 'TooManyContacts'\n | 'InvalidToken'\n | 'InternalError'\n}\n\nexport type HandlerOutput = HandlerError | HandlerSuccess\n"]}
@@ -17,7 +17,7 @@ export interface HandlerSuccess {
17
17
  export interface HandlerError {
18
18
  status: number;
19
19
  message?: string;
20
- error?: 'TODO';
20
+ error?: 'InvalidDid' | 'InternalError';
21
21
  }
22
22
  export type HandlerOutput = HandlerError | HandlerSuccess;
23
23
  //# sourceMappingURL=removeData.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"removeData.d.ts","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/removeData.ts"],"names":[],"mappings":"AAgBA,MAAM,MAAM,WAAW,GAAG,EAAE,CAAA;AAE5B,MAAM,WAAW,WAAW;CAAG;AAE/B,MAAM,WAAW,YAAY;CAAG;AAEhC,MAAM,WAAW,YAAY;IAC3B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,WAAW,CAAA;CAClB;AAED,MAAM,WAAW,cAAc;IAC7B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,YAAY,CAAA;IAClB,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAA;CACpC;AAED,MAAM,WAAW,YAAY;IAC3B,MAAM,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,KAAK,CAAC,EAAE,MAAM,CAAA;CACf;AAED,MAAM,MAAM,aAAa,GAAG,YAAY,GAAG,cAAc,CAAA"}
1
+ {"version":3,"file":"removeData.d.ts","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/removeData.ts"],"names":[],"mappings":"AAgBA,MAAM,MAAM,WAAW,GAAG,EAAE,CAAA;AAE5B,MAAM,WAAW,WAAW;CAAG;AAE/B,MAAM,WAAW,YAAY;CAAG;AAEhC,MAAM,WAAW,YAAY;IAC3B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,WAAW,CAAA;CAClB;AAED,MAAM,WAAW,cAAc;IAC7B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,YAAY,CAAA;IAClB,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAA;CACpC;AAED,MAAM,WAAW,YAAY;IAC3B,MAAM,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,KAAK,CAAC,EAAE,YAAY,GAAG,eAAe,CAAA;CACvC;AAED,MAAM,MAAM,aAAa,GAAG,YAAY,GAAG,cAAc,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"removeData.js","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/removeData.ts"],"names":[],"mappings":";;AAKA,mDAA4D;AAC5D,2CAIyB;AAEzB,MAAM,QAAQ,GAAG,eAAS,EACxB,QAAQ,GAAG,mBAAS,CAAA;AACtB,MAAM,EAAE,GAAG,6BAA6B,CAAA","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'\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 HandlerInput {\n encoding: 'application/json'\n body: InputSchema\n}\n\nexport interface HandlerSuccess {\n encoding: 'application/json'\n body: OutputSchema\n headers?: { [key: string]: string }\n}\n\nexport interface HandlerError {\n status: number\n message?: string\n error?: 'TODO'\n}\n\nexport type HandlerOutput = HandlerError | HandlerSuccess\n"]}
1
+ {"version":3,"file":"removeData.js","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/removeData.ts"],"names":[],"mappings":";;AAKA,mDAA4D;AAC5D,2CAIyB;AAEzB,MAAM,QAAQ,GAAG,eAAS,EACxB,QAAQ,GAAG,mBAAS,CAAA;AACtB,MAAM,EAAE,GAAG,6BAA6B,CAAA","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'\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 HandlerInput {\n encoding: 'application/json'\n body: InputSchema\n}\n\nexport interface HandlerSuccess {\n encoding: 'application/json'\n body: OutputSchema\n headers?: { [key: string]: string }\n}\n\nexport interface HandlerError {\n status: number\n message?: string\n error?: 'InvalidDid' | 'InternalError'\n}\n\nexport type HandlerOutput = HandlerError | HandlerSuccess\n"]}
@@ -19,7 +19,7 @@ export interface HandlerSuccess {
19
19
  export interface HandlerError {
20
20
  status: number;
21
21
  message?: string;
22
- error?: 'TODO';
22
+ error?: 'RateLimitExceeded' | 'InvalidDid' | 'InvalidPhone' | 'InternalError';
23
23
  }
24
24
  export type HandlerOutput = HandlerError | HandlerSuccess;
25
25
  //# sourceMappingURL=startPhoneVerification.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"startPhoneVerification.d.ts","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/startPhoneVerification.ts"],"names":[],"mappings":"AAgBA,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,YAAY;IAC3B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,WAAW,CAAA;CAClB;AAED,MAAM,WAAW,cAAc;IAC7B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,YAAY,CAAA;IAClB,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAA;CACpC;AAED,MAAM,WAAW,YAAY;IAC3B,MAAM,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,KAAK,CAAC,EAAE,MAAM,CAAA;CACf;AAED,MAAM,MAAM,aAAa,GAAG,YAAY,GAAG,cAAc,CAAA"}
1
+ {"version":3,"file":"startPhoneVerification.d.ts","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/startPhoneVerification.ts"],"names":[],"mappings":"AAgBA,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,YAAY;IAC3B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,WAAW,CAAA;CAClB;AAED,MAAM,WAAW,cAAc;IAC7B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,YAAY,CAAA;IAClB,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAA;CACpC;AAED,MAAM,WAAW,YAAY;IAC3B,MAAM,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,KAAK,CAAC,EAAE,mBAAmB,GAAG,YAAY,GAAG,cAAc,GAAG,eAAe,CAAA;CAC9E;AAED,MAAM,MAAM,aAAa,GAAG,YAAY,GAAG,cAAc,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"startPhoneVerification.js","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/startPhoneVerification.ts"],"names":[],"mappings":";;AAKA,mDAA4D;AAC5D,2CAIyB;AAEzB,MAAM,QAAQ,GAAG,eAAS,EACxB,QAAQ,GAAG,mBAAS,CAAA;AACtB,MAAM,EAAE,GAAG,yCAAyC,CAAA","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'\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 HandlerInput {\n encoding: 'application/json'\n body: InputSchema\n}\n\nexport interface HandlerSuccess {\n encoding: 'application/json'\n body: OutputSchema\n headers?: { [key: string]: string }\n}\n\nexport interface HandlerError {\n status: number\n message?: string\n error?: 'TODO'\n}\n\nexport type HandlerOutput = HandlerError | HandlerSuccess\n"]}
1
+ {"version":3,"file":"startPhoneVerification.js","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/startPhoneVerification.ts"],"names":[],"mappings":";;AAKA,mDAA4D;AAC5D,2CAIyB;AAEzB,MAAM,QAAQ,GAAG,eAAS,EACxB,QAAQ,GAAG,mBAAS,CAAA;AACtB,MAAM,EAAE,GAAG,yCAAyC,CAAA","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'\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 HandlerInput {\n encoding: 'application/json'\n body: InputSchema\n}\n\nexport interface HandlerSuccess {\n encoding: 'application/json'\n body: OutputSchema\n headers?: { [key: string]: string }\n}\n\nexport interface HandlerError {\n status: number\n message?: string\n error?: 'RateLimitExceeded' | 'InvalidDid' | 'InvalidPhone' | 'InternalError'\n}\n\nexport type HandlerOutput = HandlerError | HandlerSuccess\n"]}
@@ -23,7 +23,7 @@ export interface HandlerSuccess {
23
23
  export interface HandlerError {
24
24
  status: number;
25
25
  message?: string;
26
- error?: 'TODO';
26
+ error?: 'RateLimitExceeded' | 'InvalidDid' | 'InvalidPhone' | 'InvalidCode' | 'InternalError';
27
27
  }
28
28
  export type HandlerOutput = HandlerError | HandlerSuccess;
29
29
  //# sourceMappingURL=verifyPhone.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"verifyPhone.d.ts","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/verifyPhone.ts"],"names":[],"mappings":"AAgBA,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,YAAY;IAC3B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,WAAW,CAAA;CAClB;AAED,MAAM,WAAW,cAAc;IAC7B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,YAAY,CAAA;IAClB,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAA;CACpC;AAED,MAAM,WAAW,YAAY;IAC3B,MAAM,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,KAAK,CAAC,EAAE,MAAM,CAAA;CACf;AAED,MAAM,MAAM,aAAa,GAAG,YAAY,GAAG,cAAc,CAAA"}
1
+ {"version":3,"file":"verifyPhone.d.ts","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/verifyPhone.ts"],"names":[],"mappings":"AAgBA,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,YAAY;IAC3B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,WAAW,CAAA;CAClB;AAED,MAAM,WAAW,cAAc;IAC7B,QAAQ,EAAE,kBAAkB,CAAA;IAC5B,IAAI,EAAE,YAAY,CAAA;IAClB,OAAO,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAE,CAAA;CACpC;AAED,MAAM,WAAW,YAAY;IAC3B,MAAM,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,KAAK,CAAC,EACF,mBAAmB,GACnB,YAAY,GACZ,cAAc,GACd,aAAa,GACb,eAAe,CAAA;CACpB;AAED,MAAM,MAAM,aAAa,GAAG,YAAY,GAAG,cAAc,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"verifyPhone.js","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/verifyPhone.ts"],"names":[],"mappings":";;AAKA,mDAA4D;AAC5D,2CAIyB;AAEzB,MAAM,QAAQ,GAAG,eAAS,EACxB,QAAQ,GAAG,mBAAS,CAAA;AACtB,MAAM,EAAE,GAAG,8BAA8B,CAAA","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'\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 HandlerInput {\n encoding: 'application/json'\n body: InputSchema\n}\n\nexport interface HandlerSuccess {\n encoding: 'application/json'\n body: OutputSchema\n headers?: { [key: string]: string }\n}\n\nexport interface HandlerError {\n status: number\n message?: string\n error?: 'TODO'\n}\n\nexport type HandlerOutput = HandlerError | HandlerSuccess\n"]}
1
+ {"version":3,"file":"verifyPhone.js","sourceRoot":"","sources":["../../../../../../src/lexicon/types/app/bsky/contact/verifyPhone.ts"],"names":[],"mappings":";;AAKA,mDAA4D;AAC5D,2CAIyB;AAEzB,MAAM,QAAQ,GAAG,eAAS,EACxB,QAAQ,GAAG,mBAAS,CAAA;AACtB,MAAM,EAAE,GAAG,8BAA8B,CAAA","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'\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 HandlerInput {\n encoding: 'application/json'\n body: InputSchema\n}\n\nexport interface HandlerSuccess {\n encoding: 'application/json'\n body: OutputSchema\n headers?: { [key: string]: string }\n}\n\nexport interface HandlerError {\n status: number\n message?: string\n error?:\n | 'RateLimitExceeded'\n | 'InvalidDid'\n | 'InvalidPhone'\n | 'InvalidCode'\n | 'InternalError'\n}\n\nexport type HandlerOutput = HandlerError | HandlerSuccess\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atproto/bsky",
3
- "version": "0.0.202",
3
+ "version": "0.0.203",
4
4
  "license": "MIT",
5
5
  "description": "Reference implementation of app.bsky App View (Bluesky API)",
6
6
  "keywords": [
@@ -52,17 +52,17 @@
52
52
  "undici": "^6.19.8",
53
53
  "zod": "3.23.8",
54
54
  "@atproto-labs/fetch-node": "0.2.0",
55
- "@atproto-labs/xrpc-utils": "0.0.24",
56
- "@atproto/api": "^0.18.7",
57
55
  "@atproto/common": "^0.5.3",
56
+ "@atproto-labs/xrpc-utils": "0.0.24",
57
+ "@atproto/api": "^0.18.8",
58
58
  "@atproto/crypto": "^0.4.5",
59
59
  "@atproto/did": "^0.2.3",
60
60
  "@atproto/identity": "^0.4.10",
61
61
  "@atproto/lexicon": "^0.6.0",
62
62
  "@atproto/repo": "^0.8.12",
63
- "@atproto/sync": "^0.1.39",
64
63
  "@atproto/syntax": "^0.4.2",
65
- "@atproto/xrpc-server": "^0.10.3"
64
+ "@atproto/sync": "^0.1.39",
65
+ "@atproto/xrpc-server": "^0.10.4"
66
66
  },
67
67
  "devDependencies": {
68
68
  "@bufbuild/buf": "^1.28.1",
@@ -78,10 +78,10 @@
78
78
  "jest": "^28.1.2",
79
79
  "ts-node": "^10.8.2",
80
80
  "typescript": "^5.6.3",
81
- "@atproto/api": "^0.18.7",
81
+ "@atproto/api": "^0.18.8",
82
+ "@atproto/lex-cli": "^0.9.8",
82
83
  "@atproto/xrpc": "^0.7.7",
83
- "@atproto/pds": "^0.4.199",
84
- "@atproto/lex-cli": "^0.9.8"
84
+ "@atproto/pds": "^0.4.199"
85
85
  },
86
86
  "scripts": {
87
87
  "codegen": "lex gen-server --yes ./src/lexicon ../../lexicons/com/atproto/*/* ../../lexicons/app/bsky/*/* ../../lexicons/chat/bsky/*/*",
@@ -138,5 +138,25 @@ export const AGE_ASSURANCE_CONFIG: AppBskyAgeassuranceDefs.Config = {
138
138
  },
139
139
  ],
140
140
  },
141
+ {
142
+ countryCode: 'US',
143
+ regionCode: 'TN',
144
+ rules: [
145
+ {
146
+ $type: ids.IfAssuredOverAge,
147
+ age: 18,
148
+ access: 'full',
149
+ },
150
+ {
151
+ $type: ids.IfDeclaredOverAge,
152
+ age: 18,
153
+ access: 'full',
154
+ },
155
+ {
156
+ $type: ids.Default,
157
+ access: 'none',
158
+ },
159
+ ],
160
+ },
141
161
  ],
142
162
  }
@@ -1,6 +1,6 @@
1
1
  import { AppContext } from '../../../../context'
2
2
  import { Server } from '../../../../lexicon'
3
- import { assertRolodexOrThrowUnimplemented } from './util'
3
+ import { assertRolodexOrThrowUnimplemented, callRolodexClient } from './util'
4
4
 
5
5
  export default function (server: Server, ctx: AppContext) {
6
6
  server.app.bsky.contact.dismissMatch({
@@ -9,11 +9,12 @@ export default function (server: Server, ctx: AppContext) {
9
9
  assertRolodexOrThrowUnimplemented(ctx)
10
10
 
11
11
  const actor = auth.credentials.iss
12
- // TODO: Error handling.
13
- await ctx.rolodexClient.dismissMatch({
14
- actor,
15
- subject: input.body.subject,
16
- })
12
+ await callRolodexClient(
13
+ ctx.rolodexClient.dismissMatch({
14
+ actor,
15
+ subject: input.body.subject,
16
+ }),
17
+ )
17
18
 
18
19
  return {
19
20
  encoding: 'application/json',
@@ -14,7 +14,7 @@ import {
14
14
  } from '../../../../pipeline'
15
15
  import { RolodexClient } from '../../../../rolodex'
16
16
  import { Views } from '../../../../views'
17
- import { assertRolodexOrThrowUnimplemented } from './util'
17
+ import { assertRolodexOrThrowUnimplemented, callRolodexClient } from './util'
18
18
 
19
19
  export default function (server: Server, ctx: AppContext) {
20
20
  const getMatches = createPipeline(skeleton, hydration, noBlocks, presentation)
@@ -48,12 +48,13 @@ const skeleton = async (
48
48
  ): Promise<SkeletonState> => {
49
49
  const { params, ctx } = input
50
50
  const actor = params.hydrateCtx.viewer
51
- // TODO: Error handling.
52
- const { cursor, subjects } = await ctx.rolodexClient.getMatches({
53
- actor: params.hydrateCtx.viewer,
54
- limit: params.limit,
55
- cursor: params.cursor,
56
- })
51
+ const { cursor, subjects } = await callRolodexClient(
52
+ ctx.rolodexClient.getMatches({
53
+ actor: params.hydrateCtx.viewer,
54
+ limit: params.limit,
55
+ cursor: params.cursor,
56
+ }),
57
+ )
57
58
  return {
58
59
  actor,
59
60
  subjects,
@@ -1,7 +1,7 @@
1
1
  import { AppContext } from '../../../../context'
2
2
  import { Server } from '../../../../lexicon'
3
3
  import { SyncStatus } from '../../../../lexicon/types/app/bsky/contact/defs'
4
- import { assertRolodexOrThrowUnimplemented } from './util'
4
+ import { assertRolodexOrThrowUnimplemented, callRolodexClient } from './util'
5
5
 
6
6
  export default function (server: Server, ctx: AppContext) {
7
7
  server.app.bsky.contact.getSyncStatus({
@@ -10,10 +10,11 @@ export default function (server: Server, ctx: AppContext) {
10
10
  assertRolodexOrThrowUnimplemented(ctx)
11
11
 
12
12
  const actor = auth.credentials.iss
13
- // TODO: Error handling.
14
- const res = await ctx.rolodexClient.getSyncStatus({
15
- actor,
16
- })
13
+ const res = await callRolodexClient(
14
+ ctx.rolodexClient.getSyncStatus({
15
+ actor,
16
+ }),
17
+ )
17
18
 
18
19
  let syncStatus: SyncStatus | undefined
19
20
  if (res.status && res.status.syncedAt) {
@@ -17,7 +17,7 @@ import {
17
17
  import { ImportContactsMatch } from '../../../../proto/rolodex_pb'
18
18
  import { RolodexClient } from '../../../../rolodex'
19
19
  import { Views } from '../../../../views'
20
- import { assertRolodexOrThrowUnimplemented } from './util'
20
+ import { assertRolodexOrThrowUnimplemented, callRolodexClient } from './util'
21
21
 
22
22
  export default function (server: Server, ctx: AppContext) {
23
23
  const importContacts = createPipeline(
@@ -56,12 +56,13 @@ const skeleton = async (
56
56
  ): Promise<SkeletonState> => {
57
57
  const { params, ctx } = input
58
58
  const actor = params.hydrateCtx.viewer
59
- // TODO: Error handling.
60
- const { matches } = await ctx.rolodexClient.importContacts({
61
- actor: params.hydrateCtx.viewer,
62
- contacts: params.contacts,
63
- token: params.token,
64
- })
59
+ const { matches } = await callRolodexClient(
60
+ ctx.rolodexClient.importContacts({
61
+ actor: params.hydrateCtx.viewer,
62
+ contacts: params.contacts,
63
+ token: params.token,
64
+ }),
65
+ )
65
66
  return {
66
67
  actor,
67
68
  matches,
@@ -1,6 +1,6 @@
1
1
  import { AppContext } from '../../../../context'
2
2
  import { Server } from '../../../../lexicon'
3
- import { assertRolodexOrThrowUnimplemented } from './util'
3
+ import { assertRolodexOrThrowUnimplemented, callRolodexClient } from './util'
4
4
 
5
5
  export default function (server: Server, ctx: AppContext) {
6
6
  server.app.bsky.contact.removeData({
@@ -9,10 +9,11 @@ export default function (server: Server, ctx: AppContext) {
9
9
  assertRolodexOrThrowUnimplemented(ctx)
10
10
 
11
11
  const actor = auth.credentials.iss
12
- // TODO: Error handling.
13
- await ctx.rolodexClient.removeData({
14
- actor,
15
- })
12
+ await callRolodexClient(
13
+ ctx.rolodexClient.removeData({
14
+ actor,
15
+ }),
16
+ )
16
17
 
17
18
  return {
18
19
  encoding: 'application/json',
@@ -1,6 +1,7 @@
1
1
  import { TID } from '@atproto/common'
2
2
  import { AppContext } from '../../../../context'
3
3
  import { Server } from '../../../../lexicon'
4
+ import { Notification } from '../../../../lexicon/types/app/bsky/contact/defs'
4
5
  import { Namespaces } from '../../../../stash'
5
6
  import { assertRolodexOrThrowUnimplemented } from './util'
6
7
 
@@ -19,7 +20,7 @@ export default function (server: Server, ctx: AppContext) {
19
20
  payload: {
20
21
  from,
21
22
  to,
22
- },
23
+ } satisfies Notification,
23
24
  key: TID.nextStr(),
24
25
  })
25
26
 
@@ -1,6 +1,6 @@
1
1
  import { AppContext } from '../../../../context'
2
2
  import { Server } from '../../../../lexicon'
3
- import { assertRolodexOrThrowUnimplemented } from './util'
3
+ import { assertRolodexOrThrowUnimplemented, callRolodexClient } from './util'
4
4
 
5
5
  export default function (server: Server, ctx: AppContext) {
6
6
  server.app.bsky.contact.startPhoneVerification({
@@ -9,11 +9,12 @@ export default function (server: Server, ctx: AppContext) {
9
9
  assertRolodexOrThrowUnimplemented(ctx)
10
10
 
11
11
  const actor = auth.credentials.iss
12
- // TODO: Error handling.
13
- await ctx.rolodexClient.startPhoneVerification({
14
- actor,
15
- phone: input.body.phone,
16
- })
12
+ await callRolodexClient(
13
+ ctx.rolodexClient.startPhoneVerification({
14
+ actor,
15
+ phone: input.body.phone,
16
+ }),
17
+ )
17
18
 
18
19
  return {
19
20
  encoding: 'application/json',
@@ -1,4 +1,9 @@
1
- import { MethodNotImplementedError } from '@atproto/xrpc-server'
1
+ import { ConnectError } from '@connectrpc/connect'
2
+ import {
3
+ InternalServerError,
4
+ InvalidRequestError,
5
+ MethodNotImplementedError,
6
+ } from '@atproto/xrpc-server'
2
7
  import { AppContext } from '../../../..'
3
8
  import { RolodexClient } from '../../../../rolodex'
4
9
 
@@ -11,3 +16,77 @@ export function assertRolodexOrThrowUnimplemented(
11
16
  )
12
17
  }
13
18
  }
19
+
20
+ /**
21
+ * Converts UPPERCASE_ERROR from Rolodex to PascalCase for XRPC.
22
+ */
23
+ function convertErrorName(reason: string): string {
24
+ switch (reason) {
25
+ case 'INVALID_DID':
26
+ return 'InvalidDid'
27
+ case 'INVALID_LIMIT':
28
+ return 'InvalidLimit'
29
+ case 'INVALID_CURSOR':
30
+ return 'InvalidCursor'
31
+ case 'INVALID_CONTACTS':
32
+ return 'InvalidContacts'
33
+ case 'TOO_MANY_CONTACTS':
34
+ return 'TooManyContacts'
35
+ case 'INVALID_TOKEN':
36
+ return 'InvalidToken'
37
+ case 'RATE_LIMIT_EXCEEDED':
38
+ return 'RateLimitExceeded'
39
+ case 'INVALID_PHONE':
40
+ return 'InvalidPhone'
41
+ case 'INVALID_CODE':
42
+ return 'InvalidCode'
43
+ case 'INTERNAL_ERROR':
44
+ return 'InternalError'
45
+ default:
46
+ return reason
47
+ }
48
+ }
49
+
50
+ /**
51
+ * Helper to call Rolodex client methods and translate RPC errors to XRPC
52
+ * errors.
53
+ *
54
+ * These `reason` values need to stay in sync with the Rolodex service
55
+ */
56
+ export async function callRolodexClient<T>(caller: T) {
57
+ try {
58
+ return await caller
59
+ } catch (e) {
60
+ // might be something we want to handle
61
+ if (e instanceof ConnectError) {
62
+ /**
63
+ * https://connectrpc.com/docs/protocol#error-end-stream
64
+ */
65
+ const details = e.details?.at(0) as
66
+ | {
67
+ debug: {
68
+ reason: string
69
+ message: string
70
+ }
71
+ }
72
+ | undefined
73
+ const reason = details?.debug?.reason // e.g. INVALID_DID
74
+ // Handle known error reasons
75
+ if (reason) {
76
+ const errorName = convertErrorName(reason)
77
+ // NOTE: Don't leak e.message to the response.
78
+
79
+ if (reason === 'INTERNAL_ERROR') {
80
+ throw new InternalServerError('Upstream error', errorName, {
81
+ cause: e,
82
+ })
83
+ } else {
84
+ throw new InvalidRequestError('An error occurred', errorName, {
85
+ cause: e,
86
+ })
87
+ }
88
+ }
89
+ }
90
+ throw e
91
+ }
92
+ }
@@ -1,6 +1,6 @@
1
1
  import { AppContext } from '../../../../context'
2
2
  import { Server } from '../../../../lexicon'
3
- import { assertRolodexOrThrowUnimplemented } from './util'
3
+ import { assertRolodexOrThrowUnimplemented, callRolodexClient } from './util'
4
4
 
5
5
  export default function (server: Server, ctx: AppContext) {
6
6
  server.app.bsky.contact.verifyPhone({
@@ -9,12 +9,13 @@ export default function (server: Server, ctx: AppContext) {
9
9
  assertRolodexOrThrowUnimplemented(ctx)
10
10
 
11
11
  const actor = auth.credentials.iss
12
- // TODO: Error handling.
13
- const res = await ctx.rolodexClient.verifyPhone({
14
- actor,
15
- verificationCode: input.body.code,
16
- phone: input.body.phone,
17
- })
12
+ const res = await callRolodexClient(
13
+ ctx.rolodexClient.verifyPhone({
14
+ actor,
15
+ verificationCode: input.body.code,
16
+ phone: input.body.phone,
17
+ }),
18
+ )
18
19
 
19
20
  return {
20
21
  encoding: 'application/json',
package/src/api/index.ts CHANGED
@@ -16,6 +16,7 @@ import getMatches from './app/bsky/contact/getMatches'
16
16
  import getSyncStatus from './app/bsky/contact/getSyncStatus'
17
17
  import importContacts from './app/bsky/contact/importContacts'
18
18
  import removeData from './app/bsky/contact/removeData'
19
+ import sendNotification from './app/bsky/contact/sendNotification'
19
20
  import startPhoneVerification from './app/bsky/contact/startPhoneVerification'
20
21
  import verifyPhone from './app/bsky/contact/verifyPhone'
21
22
  import getActorFeeds from './app/bsky/feed/getActorFeeds'
@@ -108,6 +109,7 @@ export default function (server: Server, ctx: AppContext) {
108
109
  getSyncStatus(server, ctx)
109
110
  importContacts(server, ctx)
110
111
  removeData(server, ctx)
112
+ sendNotification(server, ctx)
111
113
  startPhoneVerification(server, ctx)
112
114
  verifyPhone(server, ctx)
113
115
  getActorFeeds(server, ctx)
@@ -273,7 +273,7 @@ export class ActorHydrator {
273
273
  includeTakedowns = false,
274
274
  ): Promise<NotificationDeclarations> {
275
275
  if (!uris.length) return new HydrationMap<NotificationDeclaration>()
276
- const res = await this.dataplane.getActorChatDeclarationRecords({ uris })
276
+ const res = await this.dataplane.getNotificationDeclarationRecords({ uris })
277
277
  return uris.reduce((acc, uri, i) => {
278
278
  const record = parseRecord<NotificationDeclarationRecord>(
279
279
  res.records[i],