@atproto/api 0.9.2 → 0.9.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/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @atproto/api
2
2
 
3
+ ## 0.9.3
4
+
5
+ ### Patch Changes
6
+
7
+ - [#2081](https://github.com/bluesky-social/atproto/pull/2081) [`5368245a`](https://github.com/bluesky-social/atproto/commit/5368245a6ef7095c86ad166fb04ff9bef27c3c3e) Thanks [@estrattonbailey](https://github.com/estrattonbailey)! - Add unspecced route for new onboarding `app.bsky.unspecced.getTaggedSuggestions`
8
+
3
9
  ## 0.9.2
4
10
 
5
11
  ### Patch Changes
@@ -123,6 +123,7 @@ import * as AppBskyNotificationListNotifications from './types/app/bsky/notifica
123
123
  import * as AppBskyNotificationRegisterPush from './types/app/bsky/notification/registerPush';
124
124
  import * as AppBskyNotificationUpdateSeen from './types/app/bsky/notification/updateSeen';
125
125
  import * as AppBskyUnspeccedGetPopularFeedGenerators from './types/app/bsky/unspecced/getPopularFeedGenerators';
126
+ import * as AppBskyUnspeccedGetTaggedSuggestions from './types/app/bsky/unspecced/getTaggedSuggestions';
126
127
  import * as AppBskyUnspeccedGetTimelineSkeleton from './types/app/bsky/unspecced/getTimelineSkeleton';
127
128
  import * as AppBskyUnspeccedSearchActorsSkeleton from './types/app/bsky/unspecced/searchActorsSkeleton';
128
129
  import * as AppBskyUnspeccedSearchPostsSkeleton from './types/app/bsky/unspecced/searchPostsSkeleton';
@@ -266,6 +267,7 @@ export * as AppBskyNotificationUpdateSeen from './types/app/bsky/notification/up
266
267
  export * as AppBskyRichtextFacet from './types/app/bsky/richtext/facet';
267
268
  export * as AppBskyUnspeccedDefs from './types/app/bsky/unspecced/defs';
268
269
  export * as AppBskyUnspeccedGetPopularFeedGenerators from './types/app/bsky/unspecced/getPopularFeedGenerators';
270
+ export * as AppBskyUnspeccedGetTaggedSuggestions from './types/app/bsky/unspecced/getTaggedSuggestions';
269
271
  export * as AppBskyUnspeccedGetTimelineSkeleton from './types/app/bsky/unspecced/getTimelineSkeleton';
270
272
  export * as AppBskyUnspeccedSearchActorsSkeleton from './types/app/bsky/unspecced/searchActorsSkeleton';
271
273
  export * as AppBskyUnspeccedSearchPostsSkeleton from './types/app/bsky/unspecced/searchPostsSkeleton';
@@ -747,6 +749,7 @@ export declare class AppBskyUnspeccedNS {
747
749
  _service: AtpServiceClient;
748
750
  constructor(service: AtpServiceClient);
749
751
  getPopularFeedGenerators(params?: AppBskyUnspeccedGetPopularFeedGenerators.QueryParams, opts?: AppBskyUnspeccedGetPopularFeedGenerators.CallOptions): Promise<AppBskyUnspeccedGetPopularFeedGenerators.Response>;
752
+ getTaggedSuggestions(params?: AppBskyUnspeccedGetTaggedSuggestions.QueryParams, opts?: AppBskyUnspeccedGetTaggedSuggestions.CallOptions): Promise<AppBskyUnspeccedGetTaggedSuggestions.Response>;
750
753
  getTimelineSkeleton(params?: AppBskyUnspeccedGetTimelineSkeleton.QueryParams, opts?: AppBskyUnspeccedGetTimelineSkeleton.CallOptions): Promise<AppBskyUnspeccedGetTimelineSkeleton.Response>;
751
754
  searchActorsSkeleton(params?: AppBskyUnspeccedSearchActorsSkeleton.QueryParams, opts?: AppBskyUnspeccedSearchActorsSkeleton.CallOptions): Promise<AppBskyUnspeccedSearchActorsSkeleton.Response>;
752
755
  searchPostsSkeleton(params?: AppBskyUnspeccedSearchPostsSkeleton.QueryParams, opts?: AppBskyUnspeccedSearchPostsSkeleton.CallOptions): Promise<AppBskyUnspeccedSearchPostsSkeleton.Response>;
@@ -7423,6 +7423,53 @@ export declare const schemaDict: {
7423
7423
  };
7424
7424
  };
7425
7425
  };
7426
+ AppBskyUnspeccedGetTaggedSuggestions: {
7427
+ lexicon: number;
7428
+ id: string;
7429
+ defs: {
7430
+ main: {
7431
+ type: string;
7432
+ description: string;
7433
+ parameters: {
7434
+ type: string;
7435
+ properties: {};
7436
+ };
7437
+ output: {
7438
+ encoding: string;
7439
+ schema: {
7440
+ type: string;
7441
+ required: string[];
7442
+ properties: {
7443
+ suggestions: {
7444
+ type: string;
7445
+ items: {
7446
+ type: string;
7447
+ ref: string;
7448
+ };
7449
+ };
7450
+ };
7451
+ };
7452
+ };
7453
+ };
7454
+ suggestion: {
7455
+ type: string;
7456
+ required: string[];
7457
+ properties: {
7458
+ tag: {
7459
+ type: string;
7460
+ };
7461
+ subjectType: {
7462
+ type: string;
7463
+ knownValues: string[];
7464
+ };
7465
+ subject: {
7466
+ type: string;
7467
+ format: string;
7468
+ };
7469
+ };
7470
+ };
7471
+ };
7472
+ };
7426
7473
  AppBskyUnspeccedGetTimelineSkeleton: {
7427
7474
  lexicon: number;
7428
7475
  id: string;
@@ -7729,6 +7776,7 @@ export declare const ids: {
7729
7776
  AppBskyRichtextFacet: string;
7730
7777
  AppBskyUnspeccedDefs: string;
7731
7778
  AppBskyUnspeccedGetPopularFeedGenerators: string;
7779
+ AppBskyUnspeccedGetTaggedSuggestions: string;
7732
7780
  AppBskyUnspeccedGetTimelineSkeleton: string;
7733
7781
  AppBskyUnspeccedSearchActorsSkeleton: string;
7734
7782
  AppBskyUnspeccedSearchPostsSkeleton: string;
@@ -0,0 +1,26 @@
1
+ import { Headers } from '@atproto/xrpc';
2
+ import { ValidationResult } from '@atproto/lexicon';
3
+ export interface QueryParams {
4
+ }
5
+ export type InputSchema = undefined;
6
+ export interface OutputSchema {
7
+ suggestions: Suggestion[];
8
+ [k: string]: unknown;
9
+ }
10
+ export interface CallOptions {
11
+ headers?: Headers;
12
+ }
13
+ export interface Response {
14
+ success: boolean;
15
+ headers: Headers;
16
+ data: OutputSchema;
17
+ }
18
+ export declare function toKnownErr(e: any): any;
19
+ export interface Suggestion {
20
+ tag: string;
21
+ subjectType: 'actor' | 'feed' | (string & {});
22
+ subject: string;
23
+ [k: string]: unknown;
24
+ }
25
+ export declare function isSuggestion(v: unknown): v is Suggestion;
26
+ export declare function validateSuggestion(v: unknown): ValidationResult;
package/dist/index.js CHANGED
@@ -8938,6 +8938,7 @@ __export(src_exports2, {
8938
8938
  AppBskyRichtextNS: () => AppBskyRichtextNS,
8939
8939
  AppBskyUnspeccedDefs: () => defs_exports8,
8940
8940
  AppBskyUnspeccedGetPopularFeedGenerators: () => getPopularFeedGenerators_exports,
8941
+ AppBskyUnspeccedGetTaggedSuggestions: () => getTaggedSuggestions_exports,
8941
8942
  AppBskyUnspeccedGetTimelineSkeleton: () => getTimelineSkeleton_exports,
8942
8943
  AppBskyUnspeccedNS: () => AppBskyUnspeccedNS,
8943
8944
  AppBskyUnspeccedSearchActorsSkeleton: () => searchActorsSkeleton_exports,
@@ -23503,6 +23504,53 @@ var schemaDict = {
23503
23504
  }
23504
23505
  }
23505
23506
  },
23507
+ AppBskyUnspeccedGetTaggedSuggestions: {
23508
+ lexicon: 1,
23509
+ id: "app.bsky.unspecced.getTaggedSuggestions",
23510
+ defs: {
23511
+ main: {
23512
+ type: "query",
23513
+ description: "Get a list of suggestions (feeds and users) tagged with categories",
23514
+ parameters: {
23515
+ type: "params",
23516
+ properties: {}
23517
+ },
23518
+ output: {
23519
+ encoding: "application/json",
23520
+ schema: {
23521
+ type: "object",
23522
+ required: ["suggestions"],
23523
+ properties: {
23524
+ suggestions: {
23525
+ type: "array",
23526
+ items: {
23527
+ type: "ref",
23528
+ ref: "lex:app.bsky.unspecced.getTaggedSuggestions#suggestion"
23529
+ }
23530
+ }
23531
+ }
23532
+ }
23533
+ }
23534
+ },
23535
+ suggestion: {
23536
+ type: "object",
23537
+ required: ["tag", "subjectType", "subject"],
23538
+ properties: {
23539
+ tag: {
23540
+ type: "string"
23541
+ },
23542
+ subjectType: {
23543
+ type: "string",
23544
+ knownValues: ["actor", "feed"]
23545
+ },
23546
+ subject: {
23547
+ type: "string",
23548
+ format: "uri"
23549
+ }
23550
+ }
23551
+ }
23552
+ }
23553
+ },
23506
23554
  AppBskyUnspeccedGetTimelineSkeleton: {
23507
23555
  lexicon: 1,
23508
23556
  id: "app.bsky.unspecced.getTimelineSkeleton",
@@ -25416,18 +25464,37 @@ function toKnownErr113(e) {
25416
25464
  return e;
25417
25465
  }
25418
25466
 
25467
+ // src/client/types/app/bsky/unspecced/getTaggedSuggestions.ts
25468
+ var getTaggedSuggestions_exports = {};
25469
+ __export(getTaggedSuggestions_exports, {
25470
+ isSuggestion: () => isSuggestion,
25471
+ toKnownErr: () => toKnownErr114,
25472
+ validateSuggestion: () => validateSuggestion
25473
+ });
25474
+ function toKnownErr114(e) {
25475
+ if (e instanceof XRPCError) {
25476
+ }
25477
+ return e;
25478
+ }
25479
+ function isSuggestion(v) {
25480
+ return isObj2(v) && hasProp2(v, "$type") && v.$type === "app.bsky.unspecced.getTaggedSuggestions#suggestion";
25481
+ }
25482
+ function validateSuggestion(v) {
25483
+ return lexicons.validate("app.bsky.unspecced.getTaggedSuggestions#suggestion", v);
25484
+ }
25485
+
25419
25486
  // src/client/types/app/bsky/unspecced/getTimelineSkeleton.ts
25420
25487
  var getTimelineSkeleton_exports = {};
25421
25488
  __export(getTimelineSkeleton_exports, {
25422
25489
  UnknownFeedError: () => UnknownFeedError3,
25423
- toKnownErr: () => toKnownErr114
25490
+ toKnownErr: () => toKnownErr115
25424
25491
  });
25425
25492
  var UnknownFeedError3 = class extends XRPCError {
25426
25493
  constructor(src2) {
25427
25494
  super(src2.status, src2.error, src2.message, src2.headers);
25428
25495
  }
25429
25496
  };
25430
- function toKnownErr114(e) {
25497
+ function toKnownErr115(e) {
25431
25498
  if (e instanceof XRPCError) {
25432
25499
  if (e.error === "UnknownFeed")
25433
25500
  return new UnknownFeedError3(e);
@@ -25439,14 +25506,14 @@ function toKnownErr114(e) {
25439
25506
  var searchActorsSkeleton_exports = {};
25440
25507
  __export(searchActorsSkeleton_exports, {
25441
25508
  BadQueryStringError: () => BadQueryStringError2,
25442
- toKnownErr: () => toKnownErr115
25509
+ toKnownErr: () => toKnownErr116
25443
25510
  });
25444
25511
  var BadQueryStringError2 = class extends XRPCError {
25445
25512
  constructor(src2) {
25446
25513
  super(src2.status, src2.error, src2.message, src2.headers);
25447
25514
  }
25448
25515
  };
25449
- function toKnownErr115(e) {
25516
+ function toKnownErr116(e) {
25450
25517
  if (e instanceof XRPCError) {
25451
25518
  if (e.error === "BadQueryString")
25452
25519
  return new BadQueryStringError2(e);
@@ -25458,14 +25525,14 @@ function toKnownErr115(e) {
25458
25525
  var searchPostsSkeleton_exports = {};
25459
25526
  __export(searchPostsSkeleton_exports, {
25460
25527
  BadQueryStringError: () => BadQueryStringError3,
25461
- toKnownErr: () => toKnownErr116
25528
+ toKnownErr: () => toKnownErr117
25462
25529
  });
25463
25530
  var BadQueryStringError3 = class extends XRPCError {
25464
25531
  constructor(src2) {
25465
25532
  super(src2.status, src2.error, src2.message, src2.headers);
25466
25533
  }
25467
25534
  };
25468
- function toKnownErr116(e) {
25535
+ function toKnownErr117(e) {
25469
25536
  if (e instanceof XRPCError) {
25470
25537
  if (e.error === "BadQueryString")
25471
25538
  return new BadQueryStringError3(e);
@@ -27567,19 +27634,24 @@ var AppBskyUnspeccedNS = class {
27567
27634
  throw toKnownErr113(e);
27568
27635
  });
27569
27636
  }
27637
+ getTaggedSuggestions(params2, opts) {
27638
+ return this._service.xrpc.call("app.bsky.unspecced.getTaggedSuggestions", params2, void 0, opts).catch((e) => {
27639
+ throw toKnownErr114(e);
27640
+ });
27641
+ }
27570
27642
  getTimelineSkeleton(params2, opts) {
27571
27643
  return this._service.xrpc.call("app.bsky.unspecced.getTimelineSkeleton", params2, void 0, opts).catch((e) => {
27572
- throw toKnownErr114(e);
27644
+ throw toKnownErr115(e);
27573
27645
  });
27574
27646
  }
27575
27647
  searchActorsSkeleton(params2, opts) {
27576
27648
  return this._service.xrpc.call("app.bsky.unspecced.searchActorsSkeleton", params2, void 0, opts).catch((e) => {
27577
- throw toKnownErr115(e);
27649
+ throw toKnownErr116(e);
27578
27650
  });
27579
27651
  }
27580
27652
  searchPostsSkeleton(params2, opts) {
27581
27653
  return this._service.xrpc.call("app.bsky.unspecced.searchPostsSkeleton", params2, void 0, opts).catch((e) => {
27582
- throw toKnownErr116(e);
27654
+ throw toKnownErr117(e);
27583
27655
  });
27584
27656
  }
27585
27657
  };