@karakeep/sdk 0.27.0 → 0.30.0

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 (2) hide show
  1. package/dist/index.d.ts +405 -16
  2. package/package.json +1 -1
package/dist/index.d.ts CHANGED
@@ -13,6 +13,8 @@ declare interface components {
13
13
  HighlightId: string;
14
14
  /** @example ieidlxygmwj87oxz5hxttoc8 */
15
15
  AssetId: string;
16
+ /** @example ieidlxygmwj87oxz5hxttoc8 */
17
+ BackupId: string;
16
18
  Bookmark: {
17
19
  id: string;
18
20
  createdAt: string;
@@ -26,6 +28,18 @@ declare interface components {
26
28
  summarizationStatus: "success" | "failure" | "pending" | null;
27
29
  note?: string | null;
28
30
  summary?: string | null;
31
+ /** @enum {string|null} */
32
+ source?:
33
+ | "api"
34
+ | "web"
35
+ | "cli"
36
+ | "mobile"
37
+ | "extension"
38
+ | "singlefile"
39
+ | "rss"
40
+ | "import"
41
+ | null;
42
+ userId: string;
29
43
  tags: {
30
44
  id: string;
31
45
  name: string;
@@ -42,6 +56,7 @@ declare interface components {
42
56
  imageUrl?: string | null;
43
57
  imageAssetId?: string | null;
44
58
  screenshotAssetId?: string | null;
59
+ pdfAssetId?: string | null;
45
60
  fullPageArchiveAssetId?: string | null;
46
61
  precrawledArchiveAssetId?: string | null;
47
62
  videoAssetId?: string | null;
@@ -49,6 +64,8 @@ declare interface components {
49
64
  htmlContent?: string | null;
50
65
  contentAssetId?: string | null;
51
66
  crawledAt?: string | null;
67
+ /** @enum {string|null} */
68
+ crawlStatus?: "success" | "failure" | "pending" | null;
52
69
  author?: string | null;
53
70
  publisher?: string | null;
54
71
  datePublished?: string | null;
@@ -81,13 +98,17 @@ declare interface components {
81
98
  assetType:
82
99
  | "linkHtmlContent"
83
100
  | "screenshot"
101
+ | "pdf"
84
102
  | "assetScreenshot"
85
103
  | "bannerImage"
86
104
  | "fullPageArchive"
87
105
  | "video"
88
106
  | "bookmarkAsset"
89
107
  | "precrawledArchive"
108
+ | "userUploaded"
109
+ | "avatar"
90
110
  | "unknown";
111
+ fileName?: string | null;
91
112
  }[];
92
113
  };
93
114
  PaginatedBookmarks: {
@@ -95,6 +116,23 @@ declare interface components {
95
116
  nextCursor: string | null;
96
117
  };
97
118
  Cursor: string;
119
+ List: {
120
+ id: string;
121
+ name: string;
122
+ description?: string | null;
123
+ icon: string;
124
+ parentId: string | null;
125
+ /**
126
+ * @default manual
127
+ * @enum {string}
128
+ */
129
+ type: "manual" | "smart";
130
+ query?: string | null;
131
+ public: boolean;
132
+ hasCollaborators: boolean;
133
+ /** @enum {string} */
134
+ userRole: "owner" | "editor" | "viewer" | "public";
135
+ };
98
136
  Highlight: {
99
137
  bookmarkId: string;
100
138
  startOffset: number;
@@ -110,20 +148,6 @@ declare interface components {
110
148
  userId: string;
111
149
  createdAt: string;
112
150
  };
113
- List: {
114
- id: string;
115
- name: string;
116
- description?: string | null;
117
- icon: string;
118
- parentId: string | null;
119
- /**
120
- * @default manual
121
- * @enum {string}
122
- */
123
- type: "manual" | "smart";
124
- query?: string | null;
125
- public: boolean;
126
- };
127
151
  Tag: {
128
152
  id: string;
129
153
  name: string;
@@ -152,6 +176,7 @@ declare interface components {
152
176
  TagId: components["schemas"]["TagId"];
153
177
  HighlightId: components["schemas"]["HighlightId"];
154
178
  AssetId: components["schemas"]["AssetId"];
179
+ BackupId: components["schemas"]["BackupId"];
155
180
  };
156
181
  requestBodies: never;
157
182
  headers: never;
@@ -236,6 +261,17 @@ declare interface paths {
236
261
  createdAt?: string | null;
237
262
  /** @enum {string} */
238
263
  crawlPriority?: "low" | "normal";
264
+ importSessionId?: string;
265
+ /** @enum {string} */
266
+ source?:
267
+ | "api"
268
+ | "web"
269
+ | "cli"
270
+ | "mobile"
271
+ | "extension"
272
+ | "singlefile"
273
+ | "rss"
274
+ | "import";
239
275
  } & (
240
276
  | {
241
277
  /** @enum {string} */
@@ -263,7 +299,16 @@ declare interface paths {
263
299
  };
264
300
  };
265
301
  responses: {
266
- /** @description The created bookmark */
302
+ /** @description The bookmark already exists */
303
+ 200: {
304
+ headers: {
305
+ [name: string]: unknown;
306
+ };
307
+ content: {
308
+ "application/json": components["schemas"]["Bookmark"];
309
+ };
310
+ };
311
+ /** @description The bookmark got created */
267
312
  201: {
268
313
  headers: {
269
314
  [name: string]: unknown;
@@ -481,6 +526,18 @@ declare interface paths {
481
526
  summarizationStatus: "success" | "failure" | "pending" | null;
482
527
  note?: string | null;
483
528
  summary?: string | null;
529
+ /** @enum {string|null} */
530
+ source?:
531
+ | "api"
532
+ | "web"
533
+ | "cli"
534
+ | "mobile"
535
+ | "extension"
536
+ | "singlefile"
537
+ | "rss"
538
+ | "import"
539
+ | null;
540
+ userId: string;
484
541
  };
485
542
  };
486
543
  };
@@ -543,6 +600,18 @@ declare interface paths {
543
600
  summarizationStatus: "success" | "failure" | "pending" | null;
544
601
  note?: string | null;
545
602
  summary?: string | null;
603
+ /** @enum {string|null} */
604
+ source?:
605
+ | "api"
606
+ | "web"
607
+ | "cli"
608
+ | "mobile"
609
+ | "extension"
610
+ | "singlefile"
611
+ | "rss"
612
+ | "import"
613
+ | null;
614
+ userId: string;
546
615
  };
547
616
  };
548
617
  };
@@ -680,6 +749,61 @@ declare interface paths {
680
749
  patch?: never;
681
750
  trace?: never;
682
751
  };
752
+ "/bookmarks/{bookmarkId}/lists": {
753
+ parameters: {
754
+ query?: never;
755
+ header?: never;
756
+ path?: never;
757
+ cookie?: never;
758
+ };
759
+ /**
760
+ * Get lists of a bookmark
761
+ * @description Get lists of a bookmark
762
+ */
763
+ get: {
764
+ parameters: {
765
+ query?: never;
766
+ header?: never;
767
+ path: {
768
+ bookmarkId: components["parameters"]["BookmarkId"];
769
+ };
770
+ cookie?: never;
771
+ };
772
+ requestBody?: never;
773
+ responses: {
774
+ /** @description The list of highlights */
775
+ 200: {
776
+ headers: {
777
+ [name: string]: unknown;
778
+ };
779
+ content: {
780
+ "application/json": {
781
+ lists: components["schemas"]["List"][];
782
+ };
783
+ };
784
+ };
785
+ /** @description Bookmark not found */
786
+ 404: {
787
+ headers: {
788
+ [name: string]: unknown;
789
+ };
790
+ content: {
791
+ "application/json": {
792
+ code: string;
793
+ message: string;
794
+ };
795
+ };
796
+ };
797
+ };
798
+ };
799
+ put?: never;
800
+ post?: never;
801
+ delete?: never;
802
+ options?: never;
803
+ head?: never;
804
+ patch?: never;
805
+ trace?: never;
806
+ };
683
807
  "/bookmarks/{bookmarkId}/highlights": {
684
808
  parameters: {
685
809
  query?: never;
@@ -766,12 +890,15 @@ declare interface paths {
766
890
  assetType:
767
891
  | "linkHtmlContent"
768
892
  | "screenshot"
893
+ | "pdf"
769
894
  | "assetScreenshot"
770
895
  | "bannerImage"
771
896
  | "fullPageArchive"
772
897
  | "video"
773
898
  | "bookmarkAsset"
774
899
  | "precrawledArchive"
900
+ | "userUploaded"
901
+ | "avatar"
775
902
  | "unknown";
776
903
  };
777
904
  };
@@ -789,13 +916,17 @@ declare interface paths {
789
916
  assetType:
790
917
  | "linkHtmlContent"
791
918
  | "screenshot"
919
+ | "pdf"
792
920
  | "assetScreenshot"
793
921
  | "bannerImage"
794
922
  | "fullPageArchive"
795
923
  | "video"
796
924
  | "bookmarkAsset"
797
925
  | "precrawledArchive"
926
+ | "userUploaded"
927
+ | "avatar"
798
928
  | "unknown";
929
+ fileName?: string | null;
799
930
  };
800
931
  };
801
932
  };
@@ -1315,7 +1446,13 @@ declare interface paths {
1315
1446
  */
1316
1447
  get: {
1317
1448
  parameters: {
1318
- query?: never;
1449
+ query?: {
1450
+ nameContains?: string;
1451
+ sort?: "name" | "usage" | "relevance";
1452
+ attachedBy?: "ai" | "human" | "none";
1453
+ cursor?: string;
1454
+ limit?: number | null;
1455
+ };
1319
1456
  header?: never;
1320
1457
  path?: never;
1321
1458
  cookie?: never;
@@ -1330,6 +1467,7 @@ declare interface paths {
1330
1467
  content: {
1331
1468
  "application/json": {
1332
1469
  tags: components["schemas"]["Tag"][];
1470
+ nextCursor: string | null;
1333
1471
  };
1334
1472
  };
1335
1473
  };
@@ -1781,6 +1919,7 @@ declare interface paths {
1781
1919
  "application/json": {
1782
1920
  /** @enum {string} */
1783
1921
  color?: "yellow" | "red" | "green" | "blue";
1922
+ note?: string | null;
1784
1923
  };
1785
1924
  };
1786
1925
  };
@@ -1840,6 +1979,7 @@ declare interface paths {
1840
1979
  id: string;
1841
1980
  name?: string | null;
1842
1981
  email?: string | null;
1982
+ image?: string | null;
1843
1983
  localUser: boolean;
1844
1984
  };
1845
1985
  };
@@ -1919,6 +2059,20 @@ declare interface paths {
1919
2059
  name: string;
1920
2060
  count: number;
1921
2061
  }[];
2062
+ bookmarksBySource: {
2063
+ /** @enum {string|null} */
2064
+ source:
2065
+ | "api"
2066
+ | "web"
2067
+ | "cli"
2068
+ | "mobile"
2069
+ | "extension"
2070
+ | "singlefile"
2071
+ | "rss"
2072
+ | "import"
2073
+ | null;
2074
+ count: number;
2075
+ }[];
1922
2076
  };
1923
2077
  };
1924
2078
  };
@@ -2114,6 +2268,241 @@ declare interface paths {
2114
2268
  patch?: never;
2115
2269
  trace?: never;
2116
2270
  };
2271
+ "/backups": {
2272
+ parameters: {
2273
+ query?: never;
2274
+ header?: never;
2275
+ path?: never;
2276
+ cookie?: never;
2277
+ };
2278
+ /**
2279
+ * Get all backups
2280
+ * @description Get all backups
2281
+ */
2282
+ get: {
2283
+ parameters: {
2284
+ query?: never;
2285
+ header?: never;
2286
+ path?: never;
2287
+ cookie?: never;
2288
+ };
2289
+ requestBody?: never;
2290
+ responses: {
2291
+ /** @description Object with all backups data. */
2292
+ 200: {
2293
+ headers: {
2294
+ [name: string]: unknown;
2295
+ };
2296
+ content: {
2297
+ "application/json": {
2298
+ backups: {
2299
+ id: string;
2300
+ userId: string;
2301
+ assetId: string | null;
2302
+ createdAt: string;
2303
+ size: number;
2304
+ bookmarkCount: number;
2305
+ /** @enum {string} */
2306
+ status: "pending" | "success" | "failure";
2307
+ errorMessage?: string | null;
2308
+ }[];
2309
+ };
2310
+ };
2311
+ };
2312
+ };
2313
+ };
2314
+ put?: never;
2315
+ /**
2316
+ * Trigger a new backup
2317
+ * @description Trigger a new backup
2318
+ */
2319
+ post: {
2320
+ parameters: {
2321
+ query?: never;
2322
+ header?: never;
2323
+ path?: never;
2324
+ cookie?: never;
2325
+ };
2326
+ requestBody?: never;
2327
+ responses: {
2328
+ /** @description Backup created successfully */
2329
+ 201: {
2330
+ headers: {
2331
+ [name: string]: unknown;
2332
+ };
2333
+ content: {
2334
+ "application/json": {
2335
+ id: string;
2336
+ userId: string;
2337
+ assetId: string | null;
2338
+ createdAt: string;
2339
+ size: number;
2340
+ bookmarkCount: number;
2341
+ /** @enum {string} */
2342
+ status: "pending" | "success" | "failure";
2343
+ errorMessage?: string | null;
2344
+ };
2345
+ };
2346
+ };
2347
+ };
2348
+ };
2349
+ delete?: never;
2350
+ options?: never;
2351
+ head?: never;
2352
+ patch?: never;
2353
+ trace?: never;
2354
+ };
2355
+ "/backups/{backupId}": {
2356
+ parameters: {
2357
+ query?: never;
2358
+ header?: never;
2359
+ path?: never;
2360
+ cookie?: never;
2361
+ };
2362
+ /**
2363
+ * Get a single backup
2364
+ * @description Get backup by its id
2365
+ */
2366
+ get: {
2367
+ parameters: {
2368
+ query?: never;
2369
+ header?: never;
2370
+ path: {
2371
+ backupId: components["parameters"]["BackupId"];
2372
+ };
2373
+ cookie?: never;
2374
+ };
2375
+ requestBody?: never;
2376
+ responses: {
2377
+ /** @description Object with backup data. */
2378
+ 200: {
2379
+ headers: {
2380
+ [name: string]: unknown;
2381
+ };
2382
+ content: {
2383
+ "application/json": {
2384
+ id: string;
2385
+ userId: string;
2386
+ assetId: string | null;
2387
+ createdAt: string;
2388
+ size: number;
2389
+ bookmarkCount: number;
2390
+ /** @enum {string} */
2391
+ status: "pending" | "success" | "failure";
2392
+ errorMessage?: string | null;
2393
+ };
2394
+ };
2395
+ };
2396
+ /** @description Backup not found */
2397
+ 404: {
2398
+ headers: {
2399
+ [name: string]: unknown;
2400
+ };
2401
+ content: {
2402
+ "application/json": {
2403
+ code: string;
2404
+ message: string;
2405
+ };
2406
+ };
2407
+ };
2408
+ };
2409
+ };
2410
+ put?: never;
2411
+ post?: never;
2412
+ /**
2413
+ * Delete a backup
2414
+ * @description Delete backup by its id
2415
+ */
2416
+ delete: {
2417
+ parameters: {
2418
+ query?: never;
2419
+ header?: never;
2420
+ path: {
2421
+ backupId: components["parameters"]["BackupId"];
2422
+ };
2423
+ cookie?: never;
2424
+ };
2425
+ requestBody?: never;
2426
+ responses: {
2427
+ /** @description No content - the backup was deleted */
2428
+ 204: {
2429
+ headers: {
2430
+ [name: string]: unknown;
2431
+ };
2432
+ content?: never;
2433
+ };
2434
+ /** @description Backup not found */
2435
+ 404: {
2436
+ headers: {
2437
+ [name: string]: unknown;
2438
+ };
2439
+ content: {
2440
+ "application/json": {
2441
+ code: string;
2442
+ message: string;
2443
+ };
2444
+ };
2445
+ };
2446
+ };
2447
+ };
2448
+ options?: never;
2449
+ head?: never;
2450
+ patch?: never;
2451
+ trace?: never;
2452
+ };
2453
+ "/backups/{backupId}/download": {
2454
+ parameters: {
2455
+ query?: never;
2456
+ header?: never;
2457
+ path?: never;
2458
+ cookie?: never;
2459
+ };
2460
+ /**
2461
+ * Download a backup
2462
+ * @description Download backup file
2463
+ */
2464
+ get: {
2465
+ parameters: {
2466
+ query?: never;
2467
+ header?: never;
2468
+ path: {
2469
+ backupId: components["parameters"]["BackupId"];
2470
+ };
2471
+ cookie?: never;
2472
+ };
2473
+ requestBody?: never;
2474
+ responses: {
2475
+ /** @description Backup file (zip archive) */
2476
+ 200: {
2477
+ headers: {
2478
+ [name: string]: unknown;
2479
+ };
2480
+ content: {
2481
+ "application/zip": unknown;
2482
+ };
2483
+ };
2484
+ /** @description Backup not found */
2485
+ 404: {
2486
+ headers: {
2487
+ [name: string]: unknown;
2488
+ };
2489
+ content: {
2490
+ "application/json": {
2491
+ code: string;
2492
+ message: string;
2493
+ };
2494
+ };
2495
+ };
2496
+ };
2497
+ };
2498
+ put?: never;
2499
+ post?: never;
2500
+ delete?: never;
2501
+ options?: never;
2502
+ head?: never;
2503
+ patch?: never;
2504
+ trace?: never;
2505
+ };
2117
2506
  }
2118
2507
 
2119
2508
  export { }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/package.json",
3
3
  "name": "@karakeep/sdk",
4
- "version": "0.27.0",
4
+ "version": "0.30.0",
5
5
  "description": "Typescript SDK for Karakeep",
6
6
  "license": "GNU Affero General Public License version 3",
7
7
  "keywords": [