@atproto/api 0.1.2 → 0.1.3

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/dist/index.js CHANGED
@@ -93,6 +93,7 @@ __export(src_exports, {
93
93
  AppBskyActorUpdateProfile: () => updateProfile_exports,
94
94
  AppBskyEmbedExternal: () => external_exports,
95
95
  AppBskyEmbedImages: () => images_exports,
96
+ AppBskyEmbedRecord: () => record_exports2,
96
97
  AppBskyFeedFeedViewPost: () => feedViewPost_exports,
97
98
  AppBskyFeedGetAuthorFeed: () => getAuthorFeed_exports,
98
99
  AppBskyFeedGetPostThread: () => getPostThread_exports,
@@ -172,11 +173,14 @@ __export(src_exports, {
172
173
  ComAtprotoSessionDelete: () => delete_exports2,
173
174
  ComAtprotoSessionGet: () => get_exports2,
174
175
  ComAtprotoSessionRefresh: () => refresh_exports,
176
+ ComAtprotoSyncGetBlocks: () => getBlocks_exports,
175
177
  ComAtprotoSyncGetCheckout: () => getCheckout_exports,
176
178
  ComAtprotoSyncGetCommitPath: () => getCommitPath_exports,
177
179
  ComAtprotoSyncGetHead: () => getHead_exports,
178
180
  ComAtprotoSyncGetRecord: () => getRecord_exports3,
179
181
  ComAtprotoSyncGetRepo: () => getRepo_exports2,
182
+ ComAtprotoSyncNotifyOfUpdate: () => notifyOfUpdate_exports,
183
+ ComAtprotoSyncRequestCrawl: () => requestCrawl_exports,
180
184
  ComAtprotoSyncSubscribeAllRepos: () => subscribeAllRepos_exports,
181
185
  ComNS: () => ComNS,
182
186
  ConfirmationRecord: () => ConfirmationRecord,
@@ -3367,6 +3371,7 @@ var lexObject = mod.object({
3367
3371
  type: mod.literal("object"),
3368
3372
  description: mod.string().optional(),
3369
3373
  required: mod.string().array().optional(),
3374
+ nullable: mod.string().array().optional(),
3370
3375
  properties: mod.record(mod.union([lexRefVariant, lexArray, lexBlobVariant, lexPrimitive])).optional()
3371
3376
  });
3372
3377
  var lexXrpcParameters = mod.object({
@@ -3806,10 +3811,14 @@ function object(lexicons2, path, def, value) {
3806
3811
  error: new ValidationError(`${path} must be an object`)
3807
3812
  };
3808
3813
  }
3809
- const requiredProps = new Set(def.required ?? []);
3814
+ const requiredProps = new Set(def.required);
3815
+ const nullableProps = new Set(def.nullable);
3810
3816
  let resultValue = value;
3811
3817
  if (typeof def.properties === "object") {
3812
3818
  for (const key in def.properties) {
3819
+ if (value[key] === null && nullableProps.has(key)) {
3820
+ continue;
3821
+ }
3813
3822
  const propDef = def.properties[key];
3814
3823
  const propPath = `${path}/${key}`;
3815
3824
  const validated = validateOneOf(lexicons2, propPath, propDef, value[key]);
@@ -3966,6 +3975,17 @@ function assertValidXrpcOutput(lexicons2, def, value) {
3966
3975
  return assertValidOneOf(lexicons2, "Output", def.output.schema, value, true);
3967
3976
  }
3968
3977
  }
3978
+ function assertValidXrpcMessage(lexicons2, def, value) {
3979
+ if (def.message?.schema) {
3980
+ return assertValidOneOf(
3981
+ lexicons2,
3982
+ "Message",
3983
+ def.message.schema,
3984
+ value,
3985
+ true
3986
+ );
3987
+ }
3988
+ }
3969
3989
 
3970
3990
  // ../lexicon/src/lexicons.ts
3971
3991
  var Lexicons = class {
@@ -4092,6 +4112,11 @@ var Lexicons = class {
4092
4112
  value
4093
4113
  );
4094
4114
  }
4115
+ assertValidXrpcMessage(lexUri, value) {
4116
+ lexUri = toLexUri(lexUri);
4117
+ const def = this.getDefOrThrow(lexUri, ["subscription"]);
4118
+ return assertValidXrpcMessage(this, def, value);
4119
+ }
4095
4120
  resolveLexUri(lexUri, ref) {
4096
4121
  lexUri = toLexUri(lexUri);
4097
4122
  return toLexUri(ref, lexUri);
@@ -6380,6 +6405,35 @@ var schemaDict = {
6380
6405
  }
6381
6406
  }
6382
6407
  },
6408
+ ComAtprotoSyncGetBlocks: {
6409
+ lexicon: 1,
6410
+ id: "com.atproto.sync.getBlocks",
6411
+ defs: {
6412
+ main: {
6413
+ type: "query",
6414
+ description: "Gets blocks from a given repo.",
6415
+ parameters: {
6416
+ type: "params",
6417
+ required: ["did", "cids"],
6418
+ properties: {
6419
+ did: {
6420
+ type: "string",
6421
+ description: "The DID of the repo."
6422
+ },
6423
+ cids: {
6424
+ type: "array",
6425
+ items: {
6426
+ type: "string"
6427
+ }
6428
+ }
6429
+ }
6430
+ },
6431
+ output: {
6432
+ encoding: "application/vnd.ipld.car"
6433
+ }
6434
+ }
6435
+ }
6436
+ },
6383
6437
  ComAtprotoSyncGetCheckout: {
6384
6438
  lexicon: 1,
6385
6439
  id: "com.atproto.sync.getCheckout",
@@ -6546,6 +6600,36 @@ var schemaDict = {
6546
6600
  }
6547
6601
  }
6548
6602
  },
6603
+ ComAtprotoSyncNotifyOfUpdate: {
6604
+ lexicon: 1,
6605
+ id: "com.atproto.sync.notifyOfUpdate",
6606
+ defs: {
6607
+ main: {
6608
+ type: "query",
6609
+ description: "Notify a crawling service of a recent update. Often when a long break between updates causes the connection with the crawling service to break."
6610
+ }
6611
+ }
6612
+ },
6613
+ ComAtprotoSyncRequestCrawl: {
6614
+ lexicon: 1,
6615
+ id: "com.atproto.sync.requestCrawl",
6616
+ defs: {
6617
+ main: {
6618
+ type: "query",
6619
+ description: "Request a service to persistently crawl hosted repos.",
6620
+ parameters: {
6621
+ type: "params",
6622
+ required: ["hostname"],
6623
+ properties: {
6624
+ host: {
6625
+ type: "string",
6626
+ description: "Hostname of the service that is requesting to be crawled."
6627
+ }
6628
+ }
6629
+ }
6630
+ }
6631
+ }
6632
+ },
6549
6633
  ComAtprotoSyncSubscribeAllRepos: {
6550
6634
  lexicon: 1,
6551
6635
  id: "com.atproto.sync.subscribeAllRepos",
@@ -6556,67 +6640,68 @@ var schemaDict = {
6556
6640
  parameters: {
6557
6641
  type: "params",
6558
6642
  properties: {
6559
- backfillFrom: {
6560
- type: "datetime",
6561
- description: "The last known event to backfill from. Does not dedupe as there may be an overlap in timestamps."
6643
+ cursor: {
6644
+ type: "integer",
6645
+ description: "The last known event to backfill from."
6562
6646
  }
6563
6647
  }
6564
6648
  },
6565
6649
  message: {
6566
6650
  schema: {
6567
- type: "union",
6568
- refs: [
6569
- "lex:com.atproto.sync.subscribeAllRepos#repoAppend",
6570
- "lex:com.atproto.sync.subscribeAllRepos#repoRebase"
6571
- ]
6572
- },
6573
- codes: {
6574
- "lex:com.atproto.sync.subscribeAllRepos#repoAppend": 0,
6575
- "lex:com.atproto.sync.subscribeAllRepos#repoRebase": 1
6576
- }
6577
- }
6578
- },
6579
- repoAppend: {
6580
- type: "object",
6581
- required: ["time", "repo", "commit", "blocks", "blobs"],
6582
- properties: {
6583
- time: {
6584
- type: "datetime"
6585
- },
6586
- repo: {
6587
- type: "string"
6588
- },
6589
- commit: {
6590
- type: "string"
6591
- },
6592
- prev: {
6593
- type: "string"
6594
- },
6595
- blocks: {
6596
- type: "unknown"
6597
- },
6598
- blobs: {
6599
- type: "array",
6600
- items: {
6601
- type: "string"
6651
+ type: "object",
6652
+ required: [
6653
+ "seq",
6654
+ "event",
6655
+ "repo",
6656
+ "commit",
6657
+ "prev",
6658
+ "blocks",
6659
+ "blobs",
6660
+ "time"
6661
+ ],
6662
+ nullable: ["prev"],
6663
+ properties: {
6664
+ seq: {
6665
+ type: "integer"
6666
+ },
6667
+ event: {
6668
+ type: "string",
6669
+ knownValues: ["repo_append", "rebase"]
6670
+ },
6671
+ repo: {
6672
+ type: "string"
6673
+ },
6674
+ commit: {
6675
+ type: "string"
6676
+ },
6677
+ prev: {
6678
+ type: "string"
6679
+ },
6680
+ blocks: {
6681
+ type: "unknown"
6682
+ },
6683
+ blobs: {
6684
+ type: "array",
6685
+ items: {
6686
+ type: "string"
6687
+ }
6688
+ },
6689
+ time: {
6690
+ type: "datetime"
6691
+ }
6602
6692
  }
6603
6693
  }
6604
- }
6605
- },
6606
- repoRebase: {
6607
- type: "object",
6608
- required: ["time", "repo", "commit"],
6609
- properties: {
6610
- time: {
6611
- type: "datetime"
6612
- },
6613
- repo: {
6614
- type: "string"
6615
- },
6616
- commit: {
6617
- type: "string"
6694
+ },
6695
+ infos: [
6696
+ {
6697
+ name: "OutdatedCursor"
6618
6698
  }
6619
- }
6699
+ ],
6700
+ errors: [
6701
+ {
6702
+ name: "FutureCursor"
6703
+ }
6704
+ ]
6620
6705
  }
6621
6706
  }
6622
6707
  },
@@ -7043,6 +7128,7 @@ var schemaDict = {
7043
7128
  encoding: "application/json",
7044
7129
  schema: {
7045
7130
  type: "object",
7131
+ nullable: ["description", "avatar", "banner"],
7046
7132
  properties: {
7047
7133
  displayName: {
7048
7134
  type: "string",
@@ -7237,6 +7323,64 @@ var schemaDict = {
7237
7323
  }
7238
7324
  }
7239
7325
  },
7326
+ AppBskyEmbedRecord: {
7327
+ lexicon: 1,
7328
+ id: "app.bsky.embed.record",
7329
+ description: "An representation of a record embedded in another form of content",
7330
+ defs: {
7331
+ main: {
7332
+ type: "object",
7333
+ required: ["record"],
7334
+ properties: {
7335
+ record: {
7336
+ type: "ref",
7337
+ ref: "lex:com.atproto.repo.strongRef"
7338
+ }
7339
+ }
7340
+ },
7341
+ presented: {
7342
+ type: "object",
7343
+ required: ["record"],
7344
+ properties: {
7345
+ record: {
7346
+ type: "union",
7347
+ refs: [
7348
+ "lex:app.bsky.embed.record#presentedRecord",
7349
+ "lex:app.bsky.embed.record#presentedNotFound"
7350
+ ]
7351
+ }
7352
+ }
7353
+ },
7354
+ presentedRecord: {
7355
+ type: "object",
7356
+ required: ["uri", "cid", "author", "record"],
7357
+ properties: {
7358
+ uri: {
7359
+ type: "string"
7360
+ },
7361
+ cid: {
7362
+ type: "string"
7363
+ },
7364
+ author: {
7365
+ type: "ref",
7366
+ ref: "lex:app.bsky.actor.ref#withInfo"
7367
+ },
7368
+ record: {
7369
+ type: "unknown"
7370
+ }
7371
+ }
7372
+ },
7373
+ presentedNotFound: {
7374
+ type: "object",
7375
+ required: ["uri"],
7376
+ properties: {
7377
+ uri: {
7378
+ type: "string"
7379
+ }
7380
+ }
7381
+ }
7382
+ }
7383
+ },
7240
7384
  AppBskyFeedFeedViewPost: {
7241
7385
  lexicon: 1,
7242
7386
  id: "app.bsky.feed.feedViewPost",
@@ -7627,7 +7771,8 @@ var schemaDict = {
7627
7771
  type: "union",
7628
7772
  refs: [
7629
7773
  "lex:app.bsky.embed.images",
7630
- "lex:app.bsky.embed.external"
7774
+ "lex:app.bsky.embed.external",
7775
+ "lex:app.bsky.embed.record"
7631
7776
  ]
7632
7777
  },
7633
7778
  createdAt: {
@@ -7714,7 +7859,8 @@ var schemaDict = {
7714
7859
  type: "union",
7715
7860
  refs: [
7716
7861
  "lex:app.bsky.embed.images#presented",
7717
- "lex:app.bsky.embed.external#presented"
7862
+ "lex:app.bsky.embed.external#presented",
7863
+ "lex:app.bsky.embed.record#presented"
7718
7864
  ]
7719
7865
  },
7720
7866
  replyCount: {
@@ -8820,12 +8966,23 @@ function toKnownErr33(e) {
8820
8966
  return e;
8821
8967
  }
8822
8968
 
8969
+ // src/client/types/com/atproto/sync/getBlocks.ts
8970
+ var getBlocks_exports = {};
8971
+ __export(getBlocks_exports, {
8972
+ toKnownErr: () => toKnownErr34
8973
+ });
8974
+ function toKnownErr34(e) {
8975
+ if (e instanceof XRPCError) {
8976
+ }
8977
+ return e;
8978
+ }
8979
+
8823
8980
  // src/client/types/com/atproto/sync/getCheckout.ts
8824
8981
  var getCheckout_exports = {};
8825
8982
  __export(getCheckout_exports, {
8826
- toKnownErr: () => toKnownErr34
8983
+ toKnownErr: () => toKnownErr35
8827
8984
  });
8828
- function toKnownErr34(e) {
8985
+ function toKnownErr35(e) {
8829
8986
  if (e instanceof XRPCError) {
8830
8987
  }
8831
8988
  return e;
@@ -8834,9 +8991,9 @@ function toKnownErr34(e) {
8834
8991
  // src/client/types/com/atproto/sync/getCommitPath.ts
8835
8992
  var getCommitPath_exports = {};
8836
8993
  __export(getCommitPath_exports, {
8837
- toKnownErr: () => toKnownErr35
8994
+ toKnownErr: () => toKnownErr36
8838
8995
  });
8839
- function toKnownErr35(e) {
8996
+ function toKnownErr36(e) {
8840
8997
  if (e instanceof XRPCError) {
8841
8998
  }
8842
8999
  return e;
@@ -8845,9 +9002,9 @@ function toKnownErr35(e) {
8845
9002
  // src/client/types/com/atproto/sync/getHead.ts
8846
9003
  var getHead_exports = {};
8847
9004
  __export(getHead_exports, {
8848
- toKnownErr: () => toKnownErr36
9005
+ toKnownErr: () => toKnownErr37
8849
9006
  });
8850
- function toKnownErr36(e) {
9007
+ function toKnownErr37(e) {
8851
9008
  if (e instanceof XRPCError) {
8852
9009
  }
8853
9010
  return e;
@@ -8856,9 +9013,9 @@ function toKnownErr36(e) {
8856
9013
  // src/client/types/com/atproto/sync/getRecord.ts
8857
9014
  var getRecord_exports3 = {};
8858
9015
  __export(getRecord_exports3, {
8859
- toKnownErr: () => toKnownErr37
9016
+ toKnownErr: () => toKnownErr38
8860
9017
  });
8861
- function toKnownErr37(e) {
9018
+ function toKnownErr38(e) {
8862
9019
  if (e instanceof XRPCError) {
8863
9020
  }
8864
9021
  return e;
@@ -8867,9 +9024,31 @@ function toKnownErr37(e) {
8867
9024
  // src/client/types/com/atproto/sync/getRepo.ts
8868
9025
  var getRepo_exports2 = {};
8869
9026
  __export(getRepo_exports2, {
8870
- toKnownErr: () => toKnownErr38
9027
+ toKnownErr: () => toKnownErr39
8871
9028
  });
8872
- function toKnownErr38(e) {
9029
+ function toKnownErr39(e) {
9030
+ if (e instanceof XRPCError) {
9031
+ }
9032
+ return e;
9033
+ }
9034
+
9035
+ // src/client/types/com/atproto/sync/notifyOfUpdate.ts
9036
+ var notifyOfUpdate_exports = {};
9037
+ __export(notifyOfUpdate_exports, {
9038
+ toKnownErr: () => toKnownErr40
9039
+ });
9040
+ function toKnownErr40(e) {
9041
+ if (e instanceof XRPCError) {
9042
+ }
9043
+ return e;
9044
+ }
9045
+
9046
+ // src/client/types/com/atproto/sync/requestCrawl.ts
9047
+ var requestCrawl_exports = {};
9048
+ __export(requestCrawl_exports, {
9049
+ toKnownErr: () => toKnownErr41
9050
+ });
9051
+ function toKnownErr41(e) {
8873
9052
  if (e instanceof XRPCError) {
8874
9053
  }
8875
9054
  return e;
@@ -8878,9 +9057,9 @@ function toKnownErr38(e) {
8878
9057
  // src/client/types/app/bsky/actor/getProfile.ts
8879
9058
  var getProfile_exports = {};
8880
9059
  __export(getProfile_exports, {
8881
- toKnownErr: () => toKnownErr39
9060
+ toKnownErr: () => toKnownErr42
8882
9061
  });
8883
- function toKnownErr39(e) {
9062
+ function toKnownErr42(e) {
8884
9063
  if (e instanceof XRPCError) {
8885
9064
  }
8886
9065
  return e;
@@ -8889,9 +9068,9 @@ function toKnownErr39(e) {
8889
9068
  // src/client/types/app/bsky/actor/getProfiles.ts
8890
9069
  var getProfiles_exports = {};
8891
9070
  __export(getProfiles_exports, {
8892
- toKnownErr: () => toKnownErr40
9071
+ toKnownErr: () => toKnownErr43
8893
9072
  });
8894
- function toKnownErr40(e) {
9073
+ function toKnownErr43(e) {
8895
9074
  if (e instanceof XRPCError) {
8896
9075
  }
8897
9076
  return e;
@@ -8900,9 +9079,9 @@ function toKnownErr40(e) {
8900
9079
  // src/client/types/app/bsky/actor/getSuggestions.ts
8901
9080
  var getSuggestions_exports = {};
8902
9081
  __export(getSuggestions_exports, {
8903
- toKnownErr: () => toKnownErr41
9082
+ toKnownErr: () => toKnownErr44
8904
9083
  });
8905
- function toKnownErr41(e) {
9084
+ function toKnownErr44(e) {
8906
9085
  if (e instanceof XRPCError) {
8907
9086
  }
8908
9087
  return e;
@@ -8911,9 +9090,9 @@ function toKnownErr41(e) {
8911
9090
  // src/client/types/app/bsky/actor/search.ts
8912
9091
  var search_exports = {};
8913
9092
  __export(search_exports, {
8914
- toKnownErr: () => toKnownErr42
9093
+ toKnownErr: () => toKnownErr45
8915
9094
  });
8916
- function toKnownErr42(e) {
9095
+ function toKnownErr45(e) {
8917
9096
  if (e instanceof XRPCError) {
8918
9097
  }
8919
9098
  return e;
@@ -8922,9 +9101,9 @@ function toKnownErr42(e) {
8922
9101
  // src/client/types/app/bsky/actor/searchTypeahead.ts
8923
9102
  var searchTypeahead_exports = {};
8924
9103
  __export(searchTypeahead_exports, {
8925
- toKnownErr: () => toKnownErr43
9104
+ toKnownErr: () => toKnownErr46
8926
9105
  });
8927
- function toKnownErr43(e) {
9106
+ function toKnownErr46(e) {
8928
9107
  if (e instanceof XRPCError) {
8929
9108
  }
8930
9109
  return e;
@@ -8937,7 +9116,7 @@ __export(updateProfile_exports, {
8937
9116
  InvalidBlobError: () => InvalidBlobError,
8938
9117
  InvalidImageDimensionsError: () => InvalidImageDimensionsError,
8939
9118
  InvalidMimeTypeError: () => InvalidMimeTypeError,
8940
- toKnownErr: () => toKnownErr44
9119
+ toKnownErr: () => toKnownErr47
8941
9120
  });
8942
9121
  var InvalidBlobError = class extends XRPCError {
8943
9122
  constructor(src) {
@@ -8959,7 +9138,7 @@ var InvalidImageDimensionsError = class extends XRPCError {
8959
9138
  super(src.status, src.error, src.message);
8960
9139
  }
8961
9140
  };
8962
- function toKnownErr44(e) {
9141
+ function toKnownErr47(e) {
8963
9142
  if (e instanceof XRPCError) {
8964
9143
  if (e.error === "InvalidBlob")
8965
9144
  return new InvalidBlobError(e);
@@ -8976,9 +9155,9 @@ function toKnownErr44(e) {
8976
9155
  // src/client/types/app/bsky/feed/getAuthorFeed.ts
8977
9156
  var getAuthorFeed_exports = {};
8978
9157
  __export(getAuthorFeed_exports, {
8979
- toKnownErr: () => toKnownErr45
9158
+ toKnownErr: () => toKnownErr48
8980
9159
  });
8981
- function toKnownErr45(e) {
9160
+ function toKnownErr48(e) {
8982
9161
  if (e instanceof XRPCError) {
8983
9162
  }
8984
9163
  return e;
@@ -8990,7 +9169,7 @@ __export(getPostThread_exports, {
8990
9169
  NotFoundError: () => NotFoundError,
8991
9170
  isNotFoundPost: () => isNotFoundPost,
8992
9171
  isThreadViewPost: () => isThreadViewPost,
8993
- toKnownErr: () => toKnownErr46,
9172
+ toKnownErr: () => toKnownErr49,
8994
9173
  validateNotFoundPost: () => validateNotFoundPost,
8995
9174
  validateThreadViewPost: () => validateThreadViewPost
8996
9175
  });
@@ -8999,7 +9178,7 @@ var NotFoundError = class extends XRPCError {
8999
9178
  super(src.status, src.error, src.message);
9000
9179
  }
9001
9180
  };
9002
- function toKnownErr46(e) {
9181
+ function toKnownErr49(e) {
9003
9182
  if (e instanceof XRPCError) {
9004
9183
  if (e.error === "NotFound")
9005
9184
  return new NotFoundError(e);
@@ -9022,9 +9201,9 @@ function validateNotFoundPost(v) {
9022
9201
  // src/client/types/app/bsky/feed/getRepostedBy.ts
9023
9202
  var getRepostedBy_exports = {};
9024
9203
  __export(getRepostedBy_exports, {
9025
- toKnownErr: () => toKnownErr47
9204
+ toKnownErr: () => toKnownErr50
9026
9205
  });
9027
- function toKnownErr47(e) {
9206
+ function toKnownErr50(e) {
9028
9207
  if (e instanceof XRPCError) {
9029
9208
  }
9030
9209
  return e;
@@ -9033,9 +9212,9 @@ function toKnownErr47(e) {
9033
9212
  // src/client/types/app/bsky/feed/getTimeline.ts
9034
9213
  var getTimeline_exports = {};
9035
9214
  __export(getTimeline_exports, {
9036
- toKnownErr: () => toKnownErr48
9215
+ toKnownErr: () => toKnownErr51
9037
9216
  });
9038
- function toKnownErr48(e) {
9217
+ function toKnownErr51(e) {
9039
9218
  if (e instanceof XRPCError) {
9040
9219
  }
9041
9220
  return e;
@@ -9045,10 +9224,10 @@ function toKnownErr48(e) {
9045
9224
  var getVotes_exports = {};
9046
9225
  __export(getVotes_exports, {
9047
9226
  isVote: () => isVote,
9048
- toKnownErr: () => toKnownErr49,
9227
+ toKnownErr: () => toKnownErr52,
9049
9228
  validateVote: () => validateVote
9050
9229
  });
9051
- function toKnownErr49(e) {
9230
+ function toKnownErr52(e) {
9052
9231
  if (e instanceof XRPCError) {
9053
9232
  }
9054
9233
  return e;
@@ -9063,9 +9242,9 @@ function validateVote(v) {
9063
9242
  // src/client/types/app/bsky/feed/setVote.ts
9064
9243
  var setVote_exports = {};
9065
9244
  __export(setVote_exports, {
9066
- toKnownErr: () => toKnownErr50
9245
+ toKnownErr: () => toKnownErr53
9067
9246
  });
9068
- function toKnownErr50(e) {
9247
+ function toKnownErr53(e) {
9069
9248
  if (e instanceof XRPCError) {
9070
9249
  }
9071
9250
  return e;
@@ -9074,9 +9253,9 @@ function toKnownErr50(e) {
9074
9253
  // src/client/types/app/bsky/graph/getFollowers.ts
9075
9254
  var getFollowers_exports = {};
9076
9255
  __export(getFollowers_exports, {
9077
- toKnownErr: () => toKnownErr51
9256
+ toKnownErr: () => toKnownErr54
9078
9257
  });
9079
- function toKnownErr51(e) {
9258
+ function toKnownErr54(e) {
9080
9259
  if (e instanceof XRPCError) {
9081
9260
  }
9082
9261
  return e;
@@ -9085,9 +9264,9 @@ function toKnownErr51(e) {
9085
9264
  // src/client/types/app/bsky/graph/getFollows.ts
9086
9265
  var getFollows_exports = {};
9087
9266
  __export(getFollows_exports, {
9088
- toKnownErr: () => toKnownErr52
9267
+ toKnownErr: () => toKnownErr55
9089
9268
  });
9090
- function toKnownErr52(e) {
9269
+ function toKnownErr55(e) {
9091
9270
  if (e instanceof XRPCError) {
9092
9271
  }
9093
9272
  return e;
@@ -9096,9 +9275,9 @@ function toKnownErr52(e) {
9096
9275
  // src/client/types/app/bsky/graph/getMutes.ts
9097
9276
  var getMutes_exports = {};
9098
9277
  __export(getMutes_exports, {
9099
- toKnownErr: () => toKnownErr53
9278
+ toKnownErr: () => toKnownErr56
9100
9279
  });
9101
- function toKnownErr53(e) {
9280
+ function toKnownErr56(e) {
9102
9281
  if (e instanceof XRPCError) {
9103
9282
  }
9104
9283
  return e;
@@ -9107,9 +9286,9 @@ function toKnownErr53(e) {
9107
9286
  // src/client/types/app/bsky/graph/mute.ts
9108
9287
  var mute_exports = {};
9109
9288
  __export(mute_exports, {
9110
- toKnownErr: () => toKnownErr54
9289
+ toKnownErr: () => toKnownErr57
9111
9290
  });
9112
- function toKnownErr54(e) {
9291
+ function toKnownErr57(e) {
9113
9292
  if (e instanceof XRPCError) {
9114
9293
  }
9115
9294
  return e;
@@ -9118,9 +9297,9 @@ function toKnownErr54(e) {
9118
9297
  // src/client/types/app/bsky/graph/unmute.ts
9119
9298
  var unmute_exports = {};
9120
9299
  __export(unmute_exports, {
9121
- toKnownErr: () => toKnownErr55
9300
+ toKnownErr: () => toKnownErr58
9122
9301
  });
9123
- function toKnownErr55(e) {
9302
+ function toKnownErr58(e) {
9124
9303
  if (e instanceof XRPCError) {
9125
9304
  }
9126
9305
  return e;
@@ -9129,9 +9308,9 @@ function toKnownErr55(e) {
9129
9308
  // src/client/types/app/bsky/notification/getCount.ts
9130
9309
  var getCount_exports = {};
9131
9310
  __export(getCount_exports, {
9132
- toKnownErr: () => toKnownErr56
9311
+ toKnownErr: () => toKnownErr59
9133
9312
  });
9134
- function toKnownErr56(e) {
9313
+ function toKnownErr59(e) {
9135
9314
  if (e instanceof XRPCError) {
9136
9315
  }
9137
9316
  return e;
@@ -9141,10 +9320,10 @@ function toKnownErr56(e) {
9141
9320
  var list_exports = {};
9142
9321
  __export(list_exports, {
9143
9322
  isNotification: () => isNotification,
9144
- toKnownErr: () => toKnownErr57,
9323
+ toKnownErr: () => toKnownErr60,
9145
9324
  validateNotification: () => validateNotification
9146
9325
  });
9147
- function toKnownErr57(e) {
9326
+ function toKnownErr60(e) {
9148
9327
  if (e instanceof XRPCError) {
9149
9328
  }
9150
9329
  return e;
@@ -9159,9 +9338,9 @@ function validateNotification(v) {
9159
9338
  // src/client/types/app/bsky/notification/updateSeen.ts
9160
9339
  var updateSeen_exports = {};
9161
9340
  __export(updateSeen_exports, {
9162
- toKnownErr: () => toKnownErr58
9341
+ toKnownErr: () => toKnownErr61
9163
9342
  });
9164
- function toKnownErr58(e) {
9343
+ function toKnownErr61(e) {
9165
9344
  if (e instanceof XRPCError) {
9166
9345
  }
9167
9346
  return e;
@@ -9429,24 +9608,6 @@ function validateRecordRef(v) {
9429
9608
 
9430
9609
  // src/client/types/com/atproto/sync/subscribeAllRepos.ts
9431
9610
  var subscribeAllRepos_exports = {};
9432
- __export(subscribeAllRepos_exports, {
9433
- isRepoAppend: () => isRepoAppend,
9434
- isRepoRebase: () => isRepoRebase,
9435
- validateRepoAppend: () => validateRepoAppend,
9436
- validateRepoRebase: () => validateRepoRebase
9437
- });
9438
- function isRepoAppend(v) {
9439
- return isObj2(v) && hasProp2(v, "$type") && v.$type === "com.atproto.sync.subscribeAllRepos#repoAppend";
9440
- }
9441
- function validateRepoAppend(v) {
9442
- return lexicons.validate("com.atproto.sync.subscribeAllRepos#repoAppend", v);
9443
- }
9444
- function isRepoRebase(v) {
9445
- return isObj2(v) && hasProp2(v, "$type") && v.$type === "com.atproto.sync.subscribeAllRepos#repoRebase";
9446
- }
9447
- function validateRepoRebase(v) {
9448
- return lexicons.validate("com.atproto.sync.subscribeAllRepos#repoRebase", v);
9449
- }
9450
9611
 
9451
9612
  // src/client/types/app/bsky/actor/profile.ts
9452
9613
  var profile_exports = {};
@@ -9596,20 +9757,57 @@ function validatePresentedImage(v) {
9596
9757
  return lexicons.validate("app.bsky.embed.images#presentedImage", v);
9597
9758
  }
9598
9759
 
9760
+ // src/client/types/app/bsky/embed/record.ts
9761
+ var record_exports2 = {};
9762
+ __export(record_exports2, {
9763
+ isMain: () => isMain7,
9764
+ isPresented: () => isPresented3,
9765
+ isPresentedNotFound: () => isPresentedNotFound,
9766
+ isPresentedRecord: () => isPresentedRecord,
9767
+ validateMain: () => validateMain7,
9768
+ validatePresented: () => validatePresented3,
9769
+ validatePresentedNotFound: () => validatePresentedNotFound,
9770
+ validatePresentedRecord: () => validatePresentedRecord
9771
+ });
9772
+ function isMain7(v) {
9773
+ return isObj2(v) && hasProp2(v, "$type") && (v.$type === "app.bsky.embed.record#main" || v.$type === "app.bsky.embed.record");
9774
+ }
9775
+ function validateMain7(v) {
9776
+ return lexicons.validate("app.bsky.embed.record#main", v);
9777
+ }
9778
+ function isPresented3(v) {
9779
+ return isObj2(v) && hasProp2(v, "$type") && v.$type === "app.bsky.embed.record#presented";
9780
+ }
9781
+ function validatePresented3(v) {
9782
+ return lexicons.validate("app.bsky.embed.record#presented", v);
9783
+ }
9784
+ function isPresentedRecord(v) {
9785
+ return isObj2(v) && hasProp2(v, "$type") && v.$type === "app.bsky.embed.record#presentedRecord";
9786
+ }
9787
+ function validatePresentedRecord(v) {
9788
+ return lexicons.validate("app.bsky.embed.record#presentedRecord", v);
9789
+ }
9790
+ function isPresentedNotFound(v) {
9791
+ return isObj2(v) && hasProp2(v, "$type") && v.$type === "app.bsky.embed.record#presentedNotFound";
9792
+ }
9793
+ function validatePresentedNotFound(v) {
9794
+ return lexicons.validate("app.bsky.embed.record#presentedNotFound", v);
9795
+ }
9796
+
9599
9797
  // src/client/types/app/bsky/feed/feedViewPost.ts
9600
9798
  var feedViewPost_exports = {};
9601
9799
  __export(feedViewPost_exports, {
9602
- isMain: () => isMain7,
9800
+ isMain: () => isMain8,
9603
9801
  isReasonRepost: () => isReasonRepost,
9604
9802
  isReplyRef: () => isReplyRef,
9605
- validateMain: () => validateMain7,
9803
+ validateMain: () => validateMain8,
9606
9804
  validateReasonRepost: () => validateReasonRepost,
9607
9805
  validateReplyRef: () => validateReplyRef
9608
9806
  });
9609
- function isMain7(v) {
9807
+ function isMain8(v) {
9610
9808
  return isObj2(v) && hasProp2(v, "$type") && (v.$type === "app.bsky.feed.feedViewPost#main" || v.$type === "app.bsky.feed.feedViewPost");
9611
9809
  }
9612
- function validateMain7(v) {
9810
+ function validateMain8(v) {
9613
9811
  return lexicons.validate("app.bsky.feed.feedViewPost#main", v);
9614
9812
  }
9615
9813
  function isReplyRef(v) {
@@ -9767,13 +9965,13 @@ var MAIN3 = "app.bsky.system.actorUser#main";
9767
9965
  // src/client/types/app/bsky/system/declRef.ts
9768
9966
  var declRef_exports = {};
9769
9967
  __export(declRef_exports, {
9770
- isMain: () => isMain8,
9771
- validateMain: () => validateMain8
9968
+ isMain: () => isMain9,
9969
+ validateMain: () => validateMain9
9772
9970
  });
9773
- function isMain8(v) {
9971
+ function isMain9(v) {
9774
9972
  return isObj2(v) && hasProp2(v, "$type") && (v.$type === "app.bsky.system.declRef#main" || v.$type === "app.bsky.system.declRef");
9775
9973
  }
9776
- function validateMain8(v) {
9974
+ function validateMain9(v) {
9777
9975
  return lexicons.validate("app.bsky.system.declRef#main", v);
9778
9976
  }
9779
9977
 
@@ -10056,29 +10254,44 @@ var SyncNS = class {
10056
10254
  constructor(service) {
10057
10255
  this._service = service;
10058
10256
  }
10257
+ getBlocks(params2, opts) {
10258
+ return this._service.xrpc.call("com.atproto.sync.getBlocks", params2, void 0, opts).catch((e) => {
10259
+ throw toKnownErr34(e);
10260
+ });
10261
+ }
10059
10262
  getCheckout(params2, opts) {
10060
10263
  return this._service.xrpc.call("com.atproto.sync.getCheckout", params2, void 0, opts).catch((e) => {
10061
- throw toKnownErr34(e);
10264
+ throw toKnownErr35(e);
10062
10265
  });
10063
10266
  }
10064
10267
  getCommitPath(params2, opts) {
10065
10268
  return this._service.xrpc.call("com.atproto.sync.getCommitPath", params2, void 0, opts).catch((e) => {
10066
- throw toKnownErr35(e);
10269
+ throw toKnownErr36(e);
10067
10270
  });
10068
10271
  }
10069
10272
  getHead(params2, opts) {
10070
10273
  return this._service.xrpc.call("com.atproto.sync.getHead", params2, void 0, opts).catch((e) => {
10071
- throw toKnownErr36(e);
10274
+ throw toKnownErr37(e);
10072
10275
  });
10073
10276
  }
10074
10277
  getRecord(params2, opts) {
10075
10278
  return this._service.xrpc.call("com.atproto.sync.getRecord", params2, void 0, opts).catch((e) => {
10076
- throw toKnownErr37(e);
10279
+ throw toKnownErr38(e);
10077
10280
  });
10078
10281
  }
10079
10282
  getRepo(params2, opts) {
10080
10283
  return this._service.xrpc.call("com.atproto.sync.getRepo", params2, void 0, opts).catch((e) => {
10081
- throw toKnownErr38(e);
10284
+ throw toKnownErr39(e);
10285
+ });
10286
+ }
10287
+ notifyOfUpdate(params2, opts) {
10288
+ return this._service.xrpc.call("com.atproto.sync.notifyOfUpdate", params2, void 0, opts).catch((e) => {
10289
+ throw toKnownErr40(e);
10290
+ });
10291
+ }
10292
+ requestCrawl(params2, opts) {
10293
+ return this._service.xrpc.call("com.atproto.sync.requestCrawl", params2, void 0, opts).catch((e) => {
10294
+ throw toKnownErr41(e);
10082
10295
  });
10083
10296
  }
10084
10297
  };
@@ -10106,32 +10319,32 @@ var ActorNS = class {
10106
10319
  }
10107
10320
  getProfile(params2, opts) {
10108
10321
  return this._service.xrpc.call("app.bsky.actor.getProfile", params2, void 0, opts).catch((e) => {
10109
- throw toKnownErr39(e);
10322
+ throw toKnownErr42(e);
10110
10323
  });
10111
10324
  }
10112
10325
  getProfiles(params2, opts) {
10113
10326
  return this._service.xrpc.call("app.bsky.actor.getProfiles", params2, void 0, opts).catch((e) => {
10114
- throw toKnownErr40(e);
10327
+ throw toKnownErr43(e);
10115
10328
  });
10116
10329
  }
10117
10330
  getSuggestions(params2, opts) {
10118
10331
  return this._service.xrpc.call("app.bsky.actor.getSuggestions", params2, void 0, opts).catch((e) => {
10119
- throw toKnownErr41(e);
10332
+ throw toKnownErr44(e);
10120
10333
  });
10121
10334
  }
10122
10335
  search(params2, opts) {
10123
10336
  return this._service.xrpc.call("app.bsky.actor.search", params2, void 0, opts).catch((e) => {
10124
- throw toKnownErr42(e);
10337
+ throw toKnownErr45(e);
10125
10338
  });
10126
10339
  }
10127
10340
  searchTypeahead(params2, opts) {
10128
10341
  return this._service.xrpc.call("app.bsky.actor.searchTypeahead", params2, void 0, opts).catch((e) => {
10129
- throw toKnownErr43(e);
10342
+ throw toKnownErr46(e);
10130
10343
  });
10131
10344
  }
10132
10345
  updateProfile(data, opts) {
10133
10346
  return this._service.xrpc.call("app.bsky.actor.updateProfile", opts?.qp, data, opts).catch((e) => {
10134
- throw toKnownErr44(e);
10347
+ throw toKnownErr47(e);
10135
10348
  });
10136
10349
  }
10137
10350
  };
@@ -10186,32 +10399,32 @@ var FeedNS = class {
10186
10399
  }
10187
10400
  getAuthorFeed(params2, opts) {
10188
10401
  return this._service.xrpc.call("app.bsky.feed.getAuthorFeed", params2, void 0, opts).catch((e) => {
10189
- throw toKnownErr45(e);
10402
+ throw toKnownErr48(e);
10190
10403
  });
10191
10404
  }
10192
10405
  getPostThread(params2, opts) {
10193
10406
  return this._service.xrpc.call("app.bsky.feed.getPostThread", params2, void 0, opts).catch((e) => {
10194
- throw toKnownErr46(e);
10407
+ throw toKnownErr49(e);
10195
10408
  });
10196
10409
  }
10197
10410
  getRepostedBy(params2, opts) {
10198
10411
  return this._service.xrpc.call("app.bsky.feed.getRepostedBy", params2, void 0, opts).catch((e) => {
10199
- throw toKnownErr47(e);
10412
+ throw toKnownErr50(e);
10200
10413
  });
10201
10414
  }
10202
10415
  getTimeline(params2, opts) {
10203
10416
  return this._service.xrpc.call("app.bsky.feed.getTimeline", params2, void 0, opts).catch((e) => {
10204
- throw toKnownErr48(e);
10417
+ throw toKnownErr51(e);
10205
10418
  });
10206
10419
  }
10207
10420
  getVotes(params2, opts) {
10208
10421
  return this._service.xrpc.call("app.bsky.feed.getVotes", params2, void 0, opts).catch((e) => {
10209
- throw toKnownErr49(e);
10422
+ throw toKnownErr52(e);
10210
10423
  });
10211
10424
  }
10212
10425
  setVote(data, opts) {
10213
10426
  return this._service.xrpc.call("app.bsky.feed.setVote", opts?.qp, data, opts).catch((e) => {
10214
- throw toKnownErr50(e);
10427
+ throw toKnownErr53(e);
10215
10428
  });
10216
10429
  }
10217
10430
  };
@@ -10335,27 +10548,27 @@ var GraphNS = class {
10335
10548
  }
10336
10549
  getFollowers(params2, opts) {
10337
10550
  return this._service.xrpc.call("app.bsky.graph.getFollowers", params2, void 0, opts).catch((e) => {
10338
- throw toKnownErr51(e);
10551
+ throw toKnownErr54(e);
10339
10552
  });
10340
10553
  }
10341
10554
  getFollows(params2, opts) {
10342
10555
  return this._service.xrpc.call("app.bsky.graph.getFollows", params2, void 0, opts).catch((e) => {
10343
- throw toKnownErr52(e);
10556
+ throw toKnownErr55(e);
10344
10557
  });
10345
10558
  }
10346
10559
  getMutes(params2, opts) {
10347
10560
  return this._service.xrpc.call("app.bsky.graph.getMutes", params2, void 0, opts).catch((e) => {
10348
- throw toKnownErr53(e);
10561
+ throw toKnownErr56(e);
10349
10562
  });
10350
10563
  }
10351
10564
  mute(data, opts) {
10352
10565
  return this._service.xrpc.call("app.bsky.graph.mute", opts?.qp, data, opts).catch((e) => {
10353
- throw toKnownErr54(e);
10566
+ throw toKnownErr57(e);
10354
10567
  });
10355
10568
  }
10356
10569
  unmute(data, opts) {
10357
10570
  return this._service.xrpc.call("app.bsky.graph.unmute", opts?.qp, data, opts).catch((e) => {
10358
- throw toKnownErr55(e);
10571
+ throw toKnownErr58(e);
10359
10572
  });
10360
10573
  }
10361
10574
  };
@@ -10476,17 +10689,17 @@ var NotificationNS = class {
10476
10689
  }
10477
10690
  getCount(params2, opts) {
10478
10691
  return this._service.xrpc.call("app.bsky.notification.getCount", params2, void 0, opts).catch((e) => {
10479
- throw toKnownErr56(e);
10692
+ throw toKnownErr59(e);
10480
10693
  });
10481
10694
  }
10482
10695
  list(params2, opts) {
10483
10696
  return this._service.xrpc.call("app.bsky.notification.list", params2, void 0, opts).catch((e) => {
10484
- throw toKnownErr57(e);
10697
+ throw toKnownErr60(e);
10485
10698
  });
10486
10699
  }
10487
10700
  updateSeen(data, opts) {
10488
10701
  return this._service.xrpc.call("app.bsky.notification.updateSeen", opts?.qp, data, opts).catch((e) => {
10489
- throw toKnownErr58(e);
10702
+ throw toKnownErr61(e);
10490
10703
  });
10491
10704
  }
10492
10705
  };
@@ -10734,6 +10947,7 @@ function isNewSessionObject(client, v) {
10734
10947
  AppBskyActorUpdateProfile,
10735
10948
  AppBskyEmbedExternal,
10736
10949
  AppBskyEmbedImages,
10950
+ AppBskyEmbedRecord,
10737
10951
  AppBskyFeedFeedViewPost,
10738
10952
  AppBskyFeedGetAuthorFeed,
10739
10953
  AppBskyFeedGetPostThread,
@@ -10813,11 +11027,14 @@ function isNewSessionObject(client, v) {
10813
11027
  ComAtprotoSessionDelete,
10814
11028
  ComAtprotoSessionGet,
10815
11029
  ComAtprotoSessionRefresh,
11030
+ ComAtprotoSyncGetBlocks,
10816
11031
  ComAtprotoSyncGetCheckout,
10817
11032
  ComAtprotoSyncGetCommitPath,
10818
11033
  ComAtprotoSyncGetHead,
10819
11034
  ComAtprotoSyncGetRecord,
10820
11035
  ComAtprotoSyncGetRepo,
11036
+ ComAtprotoSyncNotifyOfUpdate,
11037
+ ComAtprotoSyncRequestCrawl,
10821
11038
  ComAtprotoSyncSubscribeAllRepos,
10822
11039
  ComNS,
10823
11040
  ConfirmationRecord,