karakeep-python-api 0.1.0__py3-none-any.whl

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.
@@ -0,0 +1,2901 @@
1
+ {
2
+ "openapi": "3.0.0",
3
+ "info": {
4
+ "version": "1.0.0",
5
+ "title": "Karakeep API",
6
+ "description": "The API for the Karakeep app"
7
+ },
8
+ "servers": [
9
+ {
10
+ "url": "{address}/api/v1",
11
+ "variables": {
12
+ "address": {
13
+ "default": "https://try.karakeep.app",
14
+ "description": "The address of the Karakeep server"
15
+ }
16
+ }
17
+ }
18
+ ],
19
+ "components": {
20
+ "securitySchemes": {
21
+ "bearerAuth": {
22
+ "type": "http",
23
+ "scheme": "bearer",
24
+ "bearerFormat": "JWT"
25
+ }
26
+ },
27
+ "schemas": {
28
+ "AssetId": {
29
+ "type": "string",
30
+ "example": "ieidlxygmwj87oxz5hxttoc8"
31
+ },
32
+ "BookmarkId": {
33
+ "type": "string",
34
+ "example": "ieidlxygmwj87oxz5hxttoc8"
35
+ },
36
+ "ListId": {
37
+ "type": "string",
38
+ "example": "ieidlxygmwj87oxz5hxttoc8"
39
+ },
40
+ "TagId": {
41
+ "type": "string",
42
+ "example": "ieidlxygmwj87oxz5hxttoc8"
43
+ },
44
+ "HighlightId": {
45
+ "type": "string",
46
+ "example": "ieidlxygmwj87oxz5hxttoc8"
47
+ },
48
+ "Bookmark": {
49
+ "type": "object",
50
+ "properties": {
51
+ "id": {
52
+ "type": "string"
53
+ },
54
+ "createdAt": {
55
+ "type": "string"
56
+ },
57
+ "modifiedAt": {
58
+ "type": "string",
59
+ "nullable": true
60
+ },
61
+ "title": {
62
+ "type": "string",
63
+ "nullable": true
64
+ },
65
+ "archived": {
66
+ "type": "boolean"
67
+ },
68
+ "favourited": {
69
+ "type": "boolean"
70
+ },
71
+ "taggingStatus": {
72
+ "type": "string",
73
+ "nullable": true,
74
+ "enum": [
75
+ "success",
76
+ "failure",
77
+ "pending"
78
+ ]
79
+ },
80
+ "note": {
81
+ "type": "string",
82
+ "nullable": true
83
+ },
84
+ "summary": {
85
+ "type": "string",
86
+ "nullable": true
87
+ },
88
+ "tags": {
89
+ "type": "array",
90
+ "items": {
91
+ "type": "object",
92
+ "properties": {
93
+ "id": {
94
+ "type": "string"
95
+ },
96
+ "name": {
97
+ "type": "string"
98
+ },
99
+ "attachedBy": {
100
+ "type": "string",
101
+ "enum": [
102
+ "ai",
103
+ "human"
104
+ ]
105
+ }
106
+ },
107
+ "required": [
108
+ "id",
109
+ "name",
110
+ "attachedBy"
111
+ ]
112
+ }
113
+ },
114
+ "content": {
115
+ "oneOf": [
116
+ {
117
+ "type": "object",
118
+ "properties": {
119
+ "type": {
120
+ "type": "string",
121
+ "enum": [
122
+ "link"
123
+ ]
124
+ },
125
+ "url": {
126
+ "type": "string"
127
+ },
128
+ "title": {
129
+ "type": "string",
130
+ "nullable": true
131
+ },
132
+ "description": {
133
+ "type": "string",
134
+ "nullable": true
135
+ },
136
+ "imageUrl": {
137
+ "type": "string",
138
+ "nullable": true
139
+ },
140
+ "imageAssetId": {
141
+ "type": "string",
142
+ "nullable": true
143
+ },
144
+ "screenshotAssetId": {
145
+ "type": "string",
146
+ "nullable": true
147
+ },
148
+ "fullPageArchiveAssetId": {
149
+ "type": "string",
150
+ "nullable": true
151
+ },
152
+ "precrawledArchiveAssetId": {
153
+ "type": "string",
154
+ "nullable": true
155
+ },
156
+ "videoAssetId": {
157
+ "type": "string",
158
+ "nullable": true
159
+ },
160
+ "favicon": {
161
+ "type": "string",
162
+ "nullable": true
163
+ },
164
+ "htmlContent": {
165
+ "type": "string",
166
+ "nullable": true
167
+ },
168
+ "crawledAt": {
169
+ "type": "string",
170
+ "nullable": true
171
+ },
172
+ "author": {
173
+ "type": "string",
174
+ "nullable": true
175
+ },
176
+ "publisher": {
177
+ "type": "string",
178
+ "nullable": true
179
+ },
180
+ "datePublished": {
181
+ "type": "string",
182
+ "nullable": true
183
+ },
184
+ "dateModified": {
185
+ "type": "string",
186
+ "nullable": true
187
+ }
188
+ },
189
+ "required": [
190
+ "type",
191
+ "url"
192
+ ]
193
+ },
194
+ {
195
+ "type": "object",
196
+ "properties": {
197
+ "type": {
198
+ "type": "string",
199
+ "enum": [
200
+ "text"
201
+ ]
202
+ },
203
+ "text": {
204
+ "type": "string"
205
+ },
206
+ "sourceUrl": {
207
+ "type": "string",
208
+ "nullable": true
209
+ }
210
+ },
211
+ "required": [
212
+ "type",
213
+ "text"
214
+ ]
215
+ },
216
+ {
217
+ "type": "object",
218
+ "properties": {
219
+ "type": {
220
+ "type": "string",
221
+ "enum": [
222
+ "asset"
223
+ ]
224
+ },
225
+ "assetType": {
226
+ "type": "string",
227
+ "enum": [
228
+ "image",
229
+ "pdf"
230
+ ]
231
+ },
232
+ "assetId": {
233
+ "type": "string"
234
+ },
235
+ "fileName": {
236
+ "type": "string",
237
+ "nullable": true
238
+ },
239
+ "sourceUrl": {
240
+ "type": "string",
241
+ "nullable": true
242
+ },
243
+ "size": {
244
+ "type": "number",
245
+ "nullable": true
246
+ },
247
+ "content": {
248
+ "type": "string",
249
+ "nullable": true
250
+ }
251
+ },
252
+ "required": [
253
+ "type",
254
+ "assetType",
255
+ "assetId"
256
+ ]
257
+ },
258
+ {
259
+ "type": "object",
260
+ "properties": {
261
+ "type": {
262
+ "type": "string",
263
+ "enum": [
264
+ "unknown"
265
+ ]
266
+ }
267
+ },
268
+ "required": [
269
+ "type"
270
+ ]
271
+ }
272
+ ]
273
+ },
274
+ "assets": {
275
+ "type": "array",
276
+ "items": {
277
+ "type": "object",
278
+ "properties": {
279
+ "id": {
280
+ "type": "string"
281
+ },
282
+ "assetType": {
283
+ "type": "string",
284
+ "enum": [
285
+ "screenshot",
286
+ "assetScreenshot",
287
+ "bannerImage",
288
+ "fullPageArchive",
289
+ "video",
290
+ "bookmarkAsset",
291
+ "precrawledArchive",
292
+ "unknown"
293
+ ]
294
+ }
295
+ },
296
+ "required": [
297
+ "id",
298
+ "assetType"
299
+ ]
300
+ }
301
+ }
302
+ },
303
+ "required": [
304
+ "id",
305
+ "createdAt",
306
+ "modifiedAt",
307
+ "archived",
308
+ "favourited",
309
+ "taggingStatus",
310
+ "tags",
311
+ "content",
312
+ "assets"
313
+ ]
314
+ },
315
+ "PaginatedBookmarks": {
316
+ "type": "object",
317
+ "properties": {
318
+ "bookmarks": {
319
+ "type": "array",
320
+ "items": {
321
+ "$ref": "#/components/schemas/Bookmark"
322
+ }
323
+ },
324
+ "nextCursor": {
325
+ "type": "string",
326
+ "nullable": true
327
+ }
328
+ },
329
+ "required": [
330
+ "bookmarks",
331
+ "nextCursor"
332
+ ]
333
+ },
334
+ "Cursor": {
335
+ "type": "string"
336
+ },
337
+ "Highlight": {
338
+ "type": "object",
339
+ "properties": {
340
+ "bookmarkId": {
341
+ "type": "string"
342
+ },
343
+ "startOffset": {
344
+ "type": "number"
345
+ },
346
+ "endOffset": {
347
+ "type": "number"
348
+ },
349
+ "color": {
350
+ "type": "string",
351
+ "enum": [
352
+ "yellow",
353
+ "red",
354
+ "green",
355
+ "blue"
356
+ ],
357
+ "default": "yellow"
358
+ },
359
+ "text": {
360
+ "type": "string",
361
+ "nullable": true
362
+ },
363
+ "note": {
364
+ "type": "string",
365
+ "nullable": true
366
+ },
367
+ "id": {
368
+ "type": "string"
369
+ },
370
+ "userId": {
371
+ "type": "string"
372
+ },
373
+ "createdAt": {
374
+ "type": "string"
375
+ }
376
+ },
377
+ "required": [
378
+ "bookmarkId",
379
+ "startOffset",
380
+ "endOffset",
381
+ "text",
382
+ "note",
383
+ "id",
384
+ "userId",
385
+ "createdAt"
386
+ ]
387
+ },
388
+ "List": {
389
+ "type": "object",
390
+ "properties": {
391
+ "id": {
392
+ "type": "string"
393
+ },
394
+ "name": {
395
+ "type": "string"
396
+ },
397
+ "description": {
398
+ "type": "string",
399
+ "nullable": true
400
+ },
401
+ "icon": {
402
+ "type": "string"
403
+ },
404
+ "parentId": {
405
+ "type": "string",
406
+ "nullable": true
407
+ },
408
+ "type": {
409
+ "type": "string",
410
+ "enum": [
411
+ "manual",
412
+ "smart"
413
+ ],
414
+ "default": "manual"
415
+ },
416
+ "query": {
417
+ "type": "string",
418
+ "nullable": true
419
+ }
420
+ },
421
+ "required": [
422
+ "id",
423
+ "name",
424
+ "icon",
425
+ "parentId"
426
+ ]
427
+ },
428
+ "Tag": {
429
+ "type": "object",
430
+ "properties": {
431
+ "id": {
432
+ "type": "string"
433
+ },
434
+ "name": {
435
+ "type": "string"
436
+ },
437
+ "numBookmarks": {
438
+ "type": "number"
439
+ },
440
+ "numBookmarksByAttachedType": {
441
+ "type": "object",
442
+ "properties": {
443
+ "ai": {
444
+ "type": "number"
445
+ },
446
+ "human": {
447
+ "type": "number"
448
+ }
449
+ }
450
+ }
451
+ },
452
+ "required": [
453
+ "id",
454
+ "name",
455
+ "numBookmarks",
456
+ "numBookmarksByAttachedType"
457
+ ]
458
+ },
459
+ "PaginatedHighlights": {
460
+ "type": "object",
461
+ "properties": {
462
+ "highlights": {
463
+ "type": "array",
464
+ "items": {
465
+ "$ref": "#/components/schemas/Highlight"
466
+ }
467
+ },
468
+ "nextCursor": {
469
+ "type": "string",
470
+ "nullable": true
471
+ }
472
+ },
473
+ "required": [
474
+ "highlights",
475
+ "nextCursor"
476
+ ]
477
+ }
478
+ },
479
+ "parameters": {
480
+ "AssetId": {
481
+ "schema": {
482
+ "$ref": "#/components/schemas/AssetId"
483
+ },
484
+ "required": true,
485
+ "name": "assetId",
486
+ "in": "path"
487
+ },
488
+ "BookmarkId": {
489
+ "schema": {
490
+ "$ref": "#/components/schemas/BookmarkId"
491
+ },
492
+ "required": true,
493
+ "name": "bookmarkId",
494
+ "in": "path"
495
+ },
496
+ "ListId": {
497
+ "schema": {
498
+ "$ref": "#/components/schemas/ListId"
499
+ },
500
+ "required": true,
501
+ "name": "listId",
502
+ "in": "path"
503
+ },
504
+ "TagId": {
505
+ "schema": {
506
+ "$ref": "#/components/schemas/TagId"
507
+ },
508
+ "required": true,
509
+ "name": "tagId",
510
+ "in": "path"
511
+ },
512
+ "HighlightId": {
513
+ "schema": {
514
+ "$ref": "#/components/schemas/HighlightId"
515
+ },
516
+ "required": true,
517
+ "name": "highlightId",
518
+ "in": "path"
519
+ }
520
+ }
521
+ },
522
+ "paths": {
523
+ "/bookmarks": {
524
+ "get": {
525
+ "description": "Get all bookmarks",
526
+ "summary": "Get all bookmarks",
527
+ "tags": [
528
+ "Bookmarks"
529
+ ],
530
+ "security": [
531
+ {
532
+ "bearerAuth": []
533
+ }
534
+ ],
535
+ "parameters": [
536
+ {
537
+ "schema": {
538
+ "type": "boolean"
539
+ },
540
+ "required": false,
541
+ "name": "archived",
542
+ "in": "query"
543
+ },
544
+ {
545
+ "schema": {
546
+ "type": "boolean"
547
+ },
548
+ "required": false,
549
+ "name": "favourited",
550
+ "in": "query"
551
+ },
552
+ {
553
+ "schema": {
554
+ "type": "number"
555
+ },
556
+ "required": false,
557
+ "name": "limit",
558
+ "in": "query"
559
+ },
560
+ {
561
+ "schema": {
562
+ "$ref": "#/components/schemas/Cursor"
563
+ },
564
+ "required": false,
565
+ "name": "cursor",
566
+ "in": "query"
567
+ },
568
+ {
569
+ "schema": {
570
+ "type": "boolean",
571
+ "default": true,
572
+ "description": "If set to true, bookmark's content will be included in the response. Note, this content can be large for some bookmarks."
573
+ },
574
+ "required": false,
575
+ "description": "If set to true, bookmark's content will be included in the response. Note, this content can be large for some bookmarks.",
576
+ "name": "includeContent",
577
+ "in": "query"
578
+ }
579
+ ],
580
+ "responses": {
581
+ "200": {
582
+ "description": "Object with all bookmarks data.",
583
+ "content": {
584
+ "application/json": {
585
+ "schema": {
586
+ "$ref": "#/components/schemas/PaginatedBookmarks"
587
+ }
588
+ }
589
+ }
590
+ }
591
+ }
592
+ },
593
+ "post": {
594
+ "description": "Create a new bookmark",
595
+ "summary": "Create a new bookmark",
596
+ "tags": [
597
+ "Bookmarks"
598
+ ],
599
+ "security": [
600
+ {
601
+ "bearerAuth": []
602
+ }
603
+ ],
604
+ "requestBody": {
605
+ "description": "The bookmark to create",
606
+ "content": {
607
+ "application/json": {
608
+ "schema": {
609
+ "allOf": [
610
+ {
611
+ "type": "object",
612
+ "properties": {
613
+ "title": {
614
+ "type": "string",
615
+ "nullable": true,
616
+ "maxLength": 1000
617
+ },
618
+ "archived": {
619
+ "type": "boolean"
620
+ },
621
+ "favourited": {
622
+ "type": "boolean"
623
+ },
624
+ "note": {
625
+ "type": "string"
626
+ },
627
+ "summary": {
628
+ "type": "string"
629
+ },
630
+ "createdAt": {
631
+ "type": "string",
632
+ "nullable": true
633
+ }
634
+ }
635
+ },
636
+ {
637
+ "oneOf": [
638
+ {
639
+ "type": "object",
640
+ "properties": {
641
+ "type": {
642
+ "type": "string",
643
+ "enum": [
644
+ "link"
645
+ ]
646
+ },
647
+ "url": {
648
+ "type": "string",
649
+ "format": "uri"
650
+ },
651
+ "precrawledArchiveId": {
652
+ "type": "string"
653
+ }
654
+ },
655
+ "required": [
656
+ "type",
657
+ "url"
658
+ ]
659
+ },
660
+ {
661
+ "type": "object",
662
+ "properties": {
663
+ "type": {
664
+ "type": "string",
665
+ "enum": [
666
+ "text"
667
+ ]
668
+ },
669
+ "text": {
670
+ "type": "string"
671
+ },
672
+ "sourceUrl": {
673
+ "type": "string"
674
+ }
675
+ },
676
+ "required": [
677
+ "type",
678
+ "text"
679
+ ]
680
+ },
681
+ {
682
+ "type": "object",
683
+ "properties": {
684
+ "type": {
685
+ "type": "string",
686
+ "enum": [
687
+ "asset"
688
+ ]
689
+ },
690
+ "assetType": {
691
+ "type": "string",
692
+ "enum": [
693
+ "image",
694
+ "pdf"
695
+ ]
696
+ },
697
+ "assetId": {
698
+ "type": "string"
699
+ },
700
+ "fileName": {
701
+ "type": "string"
702
+ },
703
+ "sourceUrl": {
704
+ "type": "string"
705
+ }
706
+ },
707
+ "required": [
708
+ "type",
709
+ "assetType",
710
+ "assetId"
711
+ ]
712
+ }
713
+ ]
714
+ }
715
+ ]
716
+ }
717
+ }
718
+ }
719
+ },
720
+ "responses": {
721
+ "201": {
722
+ "description": "The created bookmark",
723
+ "content": {
724
+ "application/json": {
725
+ "schema": {
726
+ "$ref": "#/components/schemas/Bookmark"
727
+ }
728
+ }
729
+ }
730
+ },
731
+ "400": {
732
+ "description": "Bad request",
733
+ "content": {
734
+ "application/json": {
735
+ "schema": {
736
+ "type": "object",
737
+ "properties": {
738
+ "code": {
739
+ "type": "string"
740
+ },
741
+ "message": {
742
+ "type": "string"
743
+ }
744
+ },
745
+ "required": [
746
+ "code",
747
+ "message"
748
+ ]
749
+ }
750
+ }
751
+ }
752
+ }
753
+ }
754
+ }
755
+ },
756
+ "/bookmarks/search": {
757
+ "get": {
758
+ "description": "Search bookmarks",
759
+ "summary": "Search bookmarks",
760
+ "tags": [
761
+ "Bookmarks"
762
+ ],
763
+ "security": [
764
+ {
765
+ "bearerAuth": []
766
+ }
767
+ ],
768
+ "parameters": [
769
+ {
770
+ "schema": {
771
+ "type": "string"
772
+ },
773
+ "required": true,
774
+ "name": "q",
775
+ "in": "query"
776
+ },
777
+ {
778
+ "schema": {
779
+ "type": "number"
780
+ },
781
+ "required": false,
782
+ "name": "limit",
783
+ "in": "query"
784
+ },
785
+ {
786
+ "schema": {
787
+ "$ref": "#/components/schemas/Cursor"
788
+ },
789
+ "required": false,
790
+ "name": "cursor",
791
+ "in": "query"
792
+ },
793
+ {
794
+ "schema": {
795
+ "type": "boolean",
796
+ "default": true,
797
+ "description": "If set to true, bookmark's content will be included in the response. Note, this content can be large for some bookmarks."
798
+ },
799
+ "required": false,
800
+ "description": "If set to true, bookmark's content will be included in the response. Note, this content can be large for some bookmarks.",
801
+ "name": "includeContent",
802
+ "in": "query"
803
+ }
804
+ ],
805
+ "responses": {
806
+ "200": {
807
+ "description": "Object with the search results.",
808
+ "content": {
809
+ "application/json": {
810
+ "schema": {
811
+ "$ref": "#/components/schemas/PaginatedBookmarks"
812
+ }
813
+ }
814
+ }
815
+ }
816
+ }
817
+ }
818
+ },
819
+ "/bookmarks/{bookmarkId}": {
820
+ "get": {
821
+ "description": "Get bookmark by its id",
822
+ "summary": "Get a single bookmark",
823
+ "tags": [
824
+ "Bookmarks"
825
+ ],
826
+ "security": [
827
+ {
828
+ "bearerAuth": []
829
+ }
830
+ ],
831
+ "parameters": [
832
+ {
833
+ "$ref": "#/components/parameters/BookmarkId"
834
+ },
835
+ {
836
+ "schema": {
837
+ "type": "boolean",
838
+ "default": true,
839
+ "description": "If set to true, bookmark's content will be included in the response. Note, this content can be large for some bookmarks."
840
+ },
841
+ "required": false,
842
+ "description": "If set to true, bookmark's content will be included in the response. Note, this content can be large for some bookmarks.",
843
+ "name": "includeContent",
844
+ "in": "query"
845
+ }
846
+ ],
847
+ "responses": {
848
+ "200": {
849
+ "description": "Object with bookmark data.",
850
+ "content": {
851
+ "application/json": {
852
+ "schema": {
853
+ "$ref": "#/components/schemas/Bookmark"
854
+ }
855
+ }
856
+ }
857
+ },
858
+ "404": {
859
+ "description": "Bookmark not found",
860
+ "content": {
861
+ "application/json": {
862
+ "schema": {
863
+ "type": "object",
864
+ "properties": {
865
+ "code": {
866
+ "type": "string"
867
+ },
868
+ "message": {
869
+ "type": "string"
870
+ }
871
+ },
872
+ "required": [
873
+ "code",
874
+ "message"
875
+ ]
876
+ }
877
+ }
878
+ }
879
+ }
880
+ }
881
+ },
882
+ "delete": {
883
+ "description": "Delete bookmark by its id",
884
+ "summary": "Delete a bookmark",
885
+ "tags": [
886
+ "Bookmarks"
887
+ ],
888
+ "security": [
889
+ {
890
+ "bearerAuth": []
891
+ }
892
+ ],
893
+ "parameters": [
894
+ {
895
+ "$ref": "#/components/parameters/BookmarkId"
896
+ }
897
+ ],
898
+ "responses": {
899
+ "204": {
900
+ "description": "No content - the bookmark was deleted"
901
+ },
902
+ "404": {
903
+ "description": "Bookmark not found",
904
+ "content": {
905
+ "application/json": {
906
+ "schema": {
907
+ "type": "object",
908
+ "properties": {
909
+ "code": {
910
+ "type": "string"
911
+ },
912
+ "message": {
913
+ "type": "string"
914
+ }
915
+ },
916
+ "required": [
917
+ "code",
918
+ "message"
919
+ ]
920
+ }
921
+ }
922
+ }
923
+ }
924
+ }
925
+ },
926
+ "patch": {
927
+ "description": "Update bookmark by its id",
928
+ "summary": "Update a bookmark",
929
+ "tags": [
930
+ "Bookmarks"
931
+ ],
932
+ "security": [
933
+ {
934
+ "bearerAuth": []
935
+ }
936
+ ],
937
+ "parameters": [
938
+ {
939
+ "$ref": "#/components/parameters/BookmarkId"
940
+ }
941
+ ],
942
+ "requestBody": {
943
+ "description": "The data to update. Only the fields you want to update need to be provided.",
944
+ "content": {
945
+ "application/json": {
946
+ "schema": {
947
+ "type": "object",
948
+ "properties": {
949
+ "archived": {
950
+ "type": "boolean"
951
+ },
952
+ "favourited": {
953
+ "type": "boolean"
954
+ },
955
+ "summary": {
956
+ "type": "string",
957
+ "nullable": true
958
+ },
959
+ "note": {
960
+ "type": "string"
961
+ },
962
+ "title": {
963
+ "type": "string",
964
+ "nullable": true,
965
+ "maxLength": 1000
966
+ },
967
+ "createdAt": {
968
+ "type": "string",
969
+ "nullable": true
970
+ },
971
+ "url": {
972
+ "type": "string",
973
+ "format": "uri"
974
+ },
975
+ "description": {
976
+ "type": "string",
977
+ "nullable": true
978
+ },
979
+ "author": {
980
+ "type": "string",
981
+ "nullable": true
982
+ },
983
+ "publisher": {
984
+ "type": "string",
985
+ "nullable": true
986
+ },
987
+ "datePublished": {
988
+ "type": "string",
989
+ "nullable": true
990
+ },
991
+ "dateModified": {
992
+ "type": "string",
993
+ "nullable": true
994
+ },
995
+ "text": {
996
+ "type": "string",
997
+ "nullable": true
998
+ },
999
+ "assetContent": {
1000
+ "type": "string",
1001
+ "nullable": true
1002
+ }
1003
+ }
1004
+ }
1005
+ }
1006
+ }
1007
+ },
1008
+ "responses": {
1009
+ "200": {
1010
+ "description": "The updated bookmark",
1011
+ "content": {
1012
+ "application/json": {
1013
+ "schema": {
1014
+ "type": "object",
1015
+ "properties": {
1016
+ "id": {
1017
+ "type": "string"
1018
+ },
1019
+ "createdAt": {
1020
+ "type": "string"
1021
+ },
1022
+ "modifiedAt": {
1023
+ "type": "string",
1024
+ "nullable": true
1025
+ },
1026
+ "title": {
1027
+ "type": "string",
1028
+ "nullable": true
1029
+ },
1030
+ "archived": {
1031
+ "type": "boolean"
1032
+ },
1033
+ "favourited": {
1034
+ "type": "boolean"
1035
+ },
1036
+ "taggingStatus": {
1037
+ "type": "string",
1038
+ "nullable": true,
1039
+ "enum": [
1040
+ "success",
1041
+ "failure",
1042
+ "pending"
1043
+ ]
1044
+ },
1045
+ "note": {
1046
+ "type": "string",
1047
+ "nullable": true
1048
+ },
1049
+ "summary": {
1050
+ "type": "string",
1051
+ "nullable": true
1052
+ }
1053
+ },
1054
+ "required": [
1055
+ "id",
1056
+ "createdAt",
1057
+ "modifiedAt",
1058
+ "archived",
1059
+ "favourited",
1060
+ "taggingStatus"
1061
+ ]
1062
+ }
1063
+ }
1064
+ }
1065
+ },
1066
+ "404": {
1067
+ "description": "Bookmark not found",
1068
+ "content": {
1069
+ "application/json": {
1070
+ "schema": {
1071
+ "type": "object",
1072
+ "properties": {
1073
+ "code": {
1074
+ "type": "string"
1075
+ },
1076
+ "message": {
1077
+ "type": "string"
1078
+ }
1079
+ },
1080
+ "required": [
1081
+ "code",
1082
+ "message"
1083
+ ]
1084
+ }
1085
+ }
1086
+ }
1087
+ }
1088
+ }
1089
+ }
1090
+ },
1091
+ "/bookmarks/{bookmarkId}/summarize": {
1092
+ "post": {
1093
+ "description": "Attaches a summary to the bookmark and returns the updated record.",
1094
+ "summary": "Summarize a bookmark",
1095
+ "tags": [
1096
+ "Bookmarks"
1097
+ ],
1098
+ "security": [
1099
+ {
1100
+ "bearerAuth": []
1101
+ }
1102
+ ],
1103
+ "parameters": [
1104
+ {
1105
+ "$ref": "#/components/parameters/BookmarkId"
1106
+ }
1107
+ ],
1108
+ "responses": {
1109
+ "200": {
1110
+ "description": "The updated bookmark with summary",
1111
+ "content": {
1112
+ "application/json": {
1113
+ "schema": {
1114
+ "type": "object",
1115
+ "properties": {
1116
+ "id": {
1117
+ "type": "string"
1118
+ },
1119
+ "createdAt": {
1120
+ "type": "string"
1121
+ },
1122
+ "modifiedAt": {
1123
+ "type": "string",
1124
+ "nullable": true
1125
+ },
1126
+ "title": {
1127
+ "type": "string",
1128
+ "nullable": true
1129
+ },
1130
+ "archived": {
1131
+ "type": "boolean"
1132
+ },
1133
+ "favourited": {
1134
+ "type": "boolean"
1135
+ },
1136
+ "taggingStatus": {
1137
+ "type": "string",
1138
+ "nullable": true,
1139
+ "enum": [
1140
+ "success",
1141
+ "failure",
1142
+ "pending"
1143
+ ]
1144
+ },
1145
+ "note": {
1146
+ "type": "string",
1147
+ "nullable": true
1148
+ },
1149
+ "summary": {
1150
+ "type": "string",
1151
+ "nullable": true
1152
+ }
1153
+ },
1154
+ "required": [
1155
+ "id",
1156
+ "createdAt",
1157
+ "modifiedAt",
1158
+ "archived",
1159
+ "favourited",
1160
+ "taggingStatus"
1161
+ ]
1162
+ }
1163
+ }
1164
+ }
1165
+ },
1166
+ "404": {
1167
+ "description": "Bookmark not found",
1168
+ "content": {
1169
+ "application/json": {
1170
+ "schema": {
1171
+ "type": "object",
1172
+ "properties": {
1173
+ "code": {
1174
+ "type": "string"
1175
+ },
1176
+ "message": {
1177
+ "type": "string"
1178
+ }
1179
+ },
1180
+ "required": [
1181
+ "code",
1182
+ "message"
1183
+ ]
1184
+ }
1185
+ }
1186
+ }
1187
+ }
1188
+ }
1189
+ }
1190
+ },
1191
+ "/bookmarks/{bookmarkId}/tags": {
1192
+ "post": {
1193
+ "description": "Attach tags to a bookmark",
1194
+ "summary": "Attach tags to a bookmark",
1195
+ "tags": [
1196
+ "Bookmarks"
1197
+ ],
1198
+ "security": [
1199
+ {
1200
+ "bearerAuth": []
1201
+ }
1202
+ ],
1203
+ "parameters": [
1204
+ {
1205
+ "$ref": "#/components/parameters/BookmarkId"
1206
+ }
1207
+ ],
1208
+ "requestBody": {
1209
+ "description": "The tags to attach.",
1210
+ "content": {
1211
+ "application/json": {
1212
+ "schema": {
1213
+ "type": "object",
1214
+ "properties": {
1215
+ "tags": {
1216
+ "type": "array",
1217
+ "items": {
1218
+ "type": "object",
1219
+ "properties": {
1220
+ "tagId": {
1221
+ "type": "string"
1222
+ },
1223
+ "tagName": {
1224
+ "type": "string"
1225
+ }
1226
+ }
1227
+ }
1228
+ }
1229
+ },
1230
+ "required": [
1231
+ "tags"
1232
+ ]
1233
+ }
1234
+ }
1235
+ }
1236
+ },
1237
+ "responses": {
1238
+ "200": {
1239
+ "description": "The list of attached tag ids",
1240
+ "content": {
1241
+ "application/json": {
1242
+ "schema": {
1243
+ "type": "object",
1244
+ "properties": {
1245
+ "attached": {
1246
+ "type": "array",
1247
+ "items": {
1248
+ "$ref": "#/components/schemas/TagId"
1249
+ }
1250
+ }
1251
+ },
1252
+ "required": [
1253
+ "attached"
1254
+ ]
1255
+ }
1256
+ }
1257
+ }
1258
+ },
1259
+ "404": {
1260
+ "description": "Bookmark not found",
1261
+ "content": {
1262
+ "application/json": {
1263
+ "schema": {
1264
+ "type": "object",
1265
+ "properties": {
1266
+ "code": {
1267
+ "type": "string"
1268
+ },
1269
+ "message": {
1270
+ "type": "string"
1271
+ }
1272
+ },
1273
+ "required": [
1274
+ "code",
1275
+ "message"
1276
+ ]
1277
+ }
1278
+ }
1279
+ }
1280
+ }
1281
+ }
1282
+ },
1283
+ "delete": {
1284
+ "description": "Detach tags from a bookmark",
1285
+ "summary": "Detach tags from a bookmark",
1286
+ "tags": [
1287
+ "Bookmarks"
1288
+ ],
1289
+ "security": [
1290
+ {
1291
+ "bearerAuth": []
1292
+ }
1293
+ ],
1294
+ "parameters": [
1295
+ {
1296
+ "$ref": "#/components/parameters/BookmarkId"
1297
+ }
1298
+ ],
1299
+ "requestBody": {
1300
+ "description": "The tags to detach.",
1301
+ "content": {
1302
+ "application/json": {
1303
+ "schema": {
1304
+ "type": "object",
1305
+ "properties": {
1306
+ "tags": {
1307
+ "type": "array",
1308
+ "items": {
1309
+ "type": "object",
1310
+ "properties": {
1311
+ "tagId": {
1312
+ "type": "string"
1313
+ },
1314
+ "tagName": {
1315
+ "type": "string"
1316
+ }
1317
+ }
1318
+ }
1319
+ }
1320
+ },
1321
+ "required": [
1322
+ "tags"
1323
+ ]
1324
+ }
1325
+ }
1326
+ }
1327
+ },
1328
+ "responses": {
1329
+ "200": {
1330
+ "description": "The list of detached tag ids",
1331
+ "content": {
1332
+ "application/json": {
1333
+ "schema": {
1334
+ "type": "object",
1335
+ "properties": {
1336
+ "detached": {
1337
+ "type": "array",
1338
+ "items": {
1339
+ "$ref": "#/components/schemas/TagId"
1340
+ }
1341
+ }
1342
+ },
1343
+ "required": [
1344
+ "detached"
1345
+ ]
1346
+ }
1347
+ }
1348
+ }
1349
+ },
1350
+ "404": {
1351
+ "description": "Bookmark not found",
1352
+ "content": {
1353
+ "application/json": {
1354
+ "schema": {
1355
+ "type": "object",
1356
+ "properties": {
1357
+ "code": {
1358
+ "type": "string"
1359
+ },
1360
+ "message": {
1361
+ "type": "string"
1362
+ }
1363
+ },
1364
+ "required": [
1365
+ "code",
1366
+ "message"
1367
+ ]
1368
+ }
1369
+ }
1370
+ }
1371
+ }
1372
+ }
1373
+ }
1374
+ },
1375
+ "/bookmarks/{bookmarkId}/highlights": {
1376
+ "get": {
1377
+ "description": "Get highlights of a bookmark",
1378
+ "summary": "Get highlights of a bookmark",
1379
+ "tags": [
1380
+ "Bookmarks"
1381
+ ],
1382
+ "security": [
1383
+ {
1384
+ "bearerAuth": []
1385
+ }
1386
+ ],
1387
+ "parameters": [
1388
+ {
1389
+ "$ref": "#/components/parameters/BookmarkId"
1390
+ }
1391
+ ],
1392
+ "responses": {
1393
+ "200": {
1394
+ "description": "The list of highlights",
1395
+ "content": {
1396
+ "application/json": {
1397
+ "schema": {
1398
+ "type": "object",
1399
+ "properties": {
1400
+ "highlights": {
1401
+ "type": "array",
1402
+ "items": {
1403
+ "$ref": "#/components/schemas/Highlight"
1404
+ }
1405
+ }
1406
+ },
1407
+ "required": [
1408
+ "highlights"
1409
+ ]
1410
+ }
1411
+ }
1412
+ }
1413
+ },
1414
+ "404": {
1415
+ "description": "Bookmark not found",
1416
+ "content": {
1417
+ "application/json": {
1418
+ "schema": {
1419
+ "type": "object",
1420
+ "properties": {
1421
+ "code": {
1422
+ "type": "string"
1423
+ },
1424
+ "message": {
1425
+ "type": "string"
1426
+ }
1427
+ },
1428
+ "required": [
1429
+ "code",
1430
+ "message"
1431
+ ]
1432
+ }
1433
+ }
1434
+ }
1435
+ }
1436
+ }
1437
+ }
1438
+ },
1439
+ "/bookmarks/{bookmarkId}/assets": {
1440
+ "post": {
1441
+ "description": "Attach a new asset to a bookmark",
1442
+ "summary": "Attach asset",
1443
+ "tags": [
1444
+ "Bookmarks"
1445
+ ],
1446
+ "security": [
1447
+ {
1448
+ "bearerAuth": []
1449
+ }
1450
+ ],
1451
+ "parameters": [
1452
+ {
1453
+ "$ref": "#/components/parameters/BookmarkId"
1454
+ }
1455
+ ],
1456
+ "requestBody": {
1457
+ "description": "The asset to attach",
1458
+ "content": {
1459
+ "application/json": {
1460
+ "schema": {
1461
+ "type": "object",
1462
+ "properties": {
1463
+ "id": {
1464
+ "type": "string"
1465
+ },
1466
+ "assetType": {
1467
+ "type": "string",
1468
+ "enum": [
1469
+ "screenshot",
1470
+ "assetScreenshot",
1471
+ "bannerImage",
1472
+ "fullPageArchive",
1473
+ "video",
1474
+ "bookmarkAsset",
1475
+ "precrawledArchive",
1476
+ "unknown"
1477
+ ]
1478
+ }
1479
+ },
1480
+ "required": [
1481
+ "id",
1482
+ "assetType"
1483
+ ]
1484
+ }
1485
+ }
1486
+ }
1487
+ },
1488
+ "responses": {
1489
+ "201": {
1490
+ "description": "The attached asset",
1491
+ "content": {
1492
+ "application/json": {
1493
+ "schema": {
1494
+ "type": "object",
1495
+ "properties": {
1496
+ "id": {
1497
+ "type": "string"
1498
+ },
1499
+ "assetType": {
1500
+ "type": "string",
1501
+ "enum": [
1502
+ "screenshot",
1503
+ "assetScreenshot",
1504
+ "bannerImage",
1505
+ "fullPageArchive",
1506
+ "video",
1507
+ "bookmarkAsset",
1508
+ "precrawledArchive",
1509
+ "unknown"
1510
+ ]
1511
+ }
1512
+ },
1513
+ "required": [
1514
+ "id",
1515
+ "assetType"
1516
+ ]
1517
+ }
1518
+ }
1519
+ }
1520
+ },
1521
+ "404": {
1522
+ "description": "Bookmark not found",
1523
+ "content": {
1524
+ "application/json": {
1525
+ "schema": {
1526
+ "type": "object",
1527
+ "properties": {
1528
+ "code": {
1529
+ "type": "string"
1530
+ },
1531
+ "message": {
1532
+ "type": "string"
1533
+ }
1534
+ },
1535
+ "required": [
1536
+ "code",
1537
+ "message"
1538
+ ]
1539
+ }
1540
+ }
1541
+ }
1542
+ }
1543
+ }
1544
+ }
1545
+ },
1546
+ "/bookmarks/{bookmarkId}/assets/{assetId}": {
1547
+ "put": {
1548
+ "description": "Replace an existing asset with a new one",
1549
+ "summary": "Replace asset",
1550
+ "tags": [
1551
+ "Bookmarks"
1552
+ ],
1553
+ "security": [
1554
+ {
1555
+ "bearerAuth": []
1556
+ }
1557
+ ],
1558
+ "parameters": [
1559
+ {
1560
+ "$ref": "#/components/parameters/BookmarkId"
1561
+ },
1562
+ {
1563
+ "$ref": "#/components/parameters/AssetId"
1564
+ }
1565
+ ],
1566
+ "requestBody": {
1567
+ "description": "The new asset to replace with",
1568
+ "content": {
1569
+ "application/json": {
1570
+ "schema": {
1571
+ "type": "object",
1572
+ "properties": {
1573
+ "assetId": {
1574
+ "type": "string"
1575
+ }
1576
+ },
1577
+ "required": [
1578
+ "assetId"
1579
+ ]
1580
+ }
1581
+ }
1582
+ }
1583
+ },
1584
+ "responses": {
1585
+ "204": {
1586
+ "description": "No content - asset was replaced successfully"
1587
+ },
1588
+ "404": {
1589
+ "description": "Bookmark not found",
1590
+ "content": {
1591
+ "application/json": {
1592
+ "schema": {
1593
+ "type": "object",
1594
+ "properties": {
1595
+ "code": {
1596
+ "type": "string"
1597
+ },
1598
+ "message": {
1599
+ "type": "string"
1600
+ }
1601
+ },
1602
+ "required": [
1603
+ "code",
1604
+ "message"
1605
+ ]
1606
+ }
1607
+ }
1608
+ }
1609
+ }
1610
+ }
1611
+ },
1612
+ "delete": {
1613
+ "description": "Detach an asset from a bookmark",
1614
+ "summary": "Detach asset",
1615
+ "tags": [
1616
+ "Bookmarks"
1617
+ ],
1618
+ "security": [
1619
+ {
1620
+ "bearerAuth": []
1621
+ }
1622
+ ],
1623
+ "parameters": [
1624
+ {
1625
+ "$ref": "#/components/parameters/BookmarkId"
1626
+ },
1627
+ {
1628
+ "$ref": "#/components/parameters/AssetId"
1629
+ }
1630
+ ],
1631
+ "responses": {
1632
+ "204": {
1633
+ "description": "No content - asset was detached successfully"
1634
+ },
1635
+ "404": {
1636
+ "description": "Bookmark not found",
1637
+ "content": {
1638
+ "application/json": {
1639
+ "schema": {
1640
+ "type": "object",
1641
+ "properties": {
1642
+ "code": {
1643
+ "type": "string"
1644
+ },
1645
+ "message": {
1646
+ "type": "string"
1647
+ }
1648
+ },
1649
+ "required": [
1650
+ "code",
1651
+ "message"
1652
+ ]
1653
+ }
1654
+ }
1655
+ }
1656
+ }
1657
+ }
1658
+ }
1659
+ },
1660
+ "/lists": {
1661
+ "get": {
1662
+ "description": "Get all lists",
1663
+ "summary": "Get all lists",
1664
+ "tags": [
1665
+ "Lists"
1666
+ ],
1667
+ "security": [
1668
+ {
1669
+ "bearerAuth": []
1670
+ }
1671
+ ],
1672
+ "responses": {
1673
+ "200": {
1674
+ "description": "Object with all lists data.",
1675
+ "content": {
1676
+ "application/json": {
1677
+ "schema": {
1678
+ "type": "object",
1679
+ "properties": {
1680
+ "lists": {
1681
+ "type": "array",
1682
+ "items": {
1683
+ "$ref": "#/components/schemas/List"
1684
+ }
1685
+ }
1686
+ },
1687
+ "required": [
1688
+ "lists"
1689
+ ]
1690
+ }
1691
+ }
1692
+ }
1693
+ }
1694
+ }
1695
+ },
1696
+ "post": {
1697
+ "description": "Create a new list",
1698
+ "summary": "Create a new list",
1699
+ "tags": [
1700
+ "Lists"
1701
+ ],
1702
+ "security": [
1703
+ {
1704
+ "bearerAuth": []
1705
+ }
1706
+ ],
1707
+ "requestBody": {
1708
+ "description": "The list to create",
1709
+ "content": {
1710
+ "application/json": {
1711
+ "schema": {
1712
+ "type": "object",
1713
+ "properties": {
1714
+ "name": {
1715
+ "type": "string",
1716
+ "minLength": 1,
1717
+ "maxLength": 40
1718
+ },
1719
+ "description": {
1720
+ "type": "string",
1721
+ "minLength": 0,
1722
+ "maxLength": 100
1723
+ },
1724
+ "icon": {
1725
+ "type": "string"
1726
+ },
1727
+ "type": {
1728
+ "type": "string",
1729
+ "enum": [
1730
+ "manual",
1731
+ "smart"
1732
+ ],
1733
+ "default": "manual"
1734
+ },
1735
+ "query": {
1736
+ "type": "string",
1737
+ "minLength": 1
1738
+ },
1739
+ "parentId": {
1740
+ "type": "string",
1741
+ "nullable": true
1742
+ }
1743
+ },
1744
+ "required": [
1745
+ "name",
1746
+ "icon"
1747
+ ]
1748
+ }
1749
+ }
1750
+ }
1751
+ },
1752
+ "responses": {
1753
+ "201": {
1754
+ "description": "The created list",
1755
+ "content": {
1756
+ "application/json": {
1757
+ "schema": {
1758
+ "$ref": "#/components/schemas/List"
1759
+ }
1760
+ }
1761
+ }
1762
+ },
1763
+ "400": {
1764
+ "description": "Bad request",
1765
+ "content": {
1766
+ "application/json": {
1767
+ "schema": {
1768
+ "type": "object",
1769
+ "properties": {
1770
+ "code": {
1771
+ "type": "string"
1772
+ },
1773
+ "message": {
1774
+ "type": "string"
1775
+ }
1776
+ },
1777
+ "required": [
1778
+ "code",
1779
+ "message"
1780
+ ]
1781
+ }
1782
+ }
1783
+ }
1784
+ }
1785
+ }
1786
+ }
1787
+ },
1788
+ "/lists/{listId}": {
1789
+ "get": {
1790
+ "description": "Get list by its id",
1791
+ "summary": "Get a single list",
1792
+ "tags": [
1793
+ "Lists"
1794
+ ],
1795
+ "security": [
1796
+ {
1797
+ "bearerAuth": []
1798
+ }
1799
+ ],
1800
+ "parameters": [
1801
+ {
1802
+ "$ref": "#/components/parameters/ListId"
1803
+ }
1804
+ ],
1805
+ "responses": {
1806
+ "200": {
1807
+ "description": "Object with list data.",
1808
+ "content": {
1809
+ "application/json": {
1810
+ "schema": {
1811
+ "$ref": "#/components/schemas/List"
1812
+ }
1813
+ }
1814
+ }
1815
+ },
1816
+ "404": {
1817
+ "description": "List not found",
1818
+ "content": {
1819
+ "application/json": {
1820
+ "schema": {
1821
+ "type": "object",
1822
+ "properties": {
1823
+ "code": {
1824
+ "type": "string"
1825
+ },
1826
+ "message": {
1827
+ "type": "string"
1828
+ }
1829
+ },
1830
+ "required": [
1831
+ "code",
1832
+ "message"
1833
+ ]
1834
+ }
1835
+ }
1836
+ }
1837
+ }
1838
+ }
1839
+ },
1840
+ "delete": {
1841
+ "description": "Delete list by its id",
1842
+ "summary": "Delete a list",
1843
+ "tags": [
1844
+ "Lists"
1845
+ ],
1846
+ "security": [
1847
+ {
1848
+ "bearerAuth": []
1849
+ }
1850
+ ],
1851
+ "parameters": [
1852
+ {
1853
+ "$ref": "#/components/parameters/ListId"
1854
+ }
1855
+ ],
1856
+ "responses": {
1857
+ "204": {
1858
+ "description": "No content - the bookmark was deleted"
1859
+ },
1860
+ "404": {
1861
+ "description": "List not found",
1862
+ "content": {
1863
+ "application/json": {
1864
+ "schema": {
1865
+ "type": "object",
1866
+ "properties": {
1867
+ "code": {
1868
+ "type": "string"
1869
+ },
1870
+ "message": {
1871
+ "type": "string"
1872
+ }
1873
+ },
1874
+ "required": [
1875
+ "code",
1876
+ "message"
1877
+ ]
1878
+ }
1879
+ }
1880
+ }
1881
+ }
1882
+ }
1883
+ },
1884
+ "patch": {
1885
+ "description": "Update list by its id",
1886
+ "summary": "Update a list",
1887
+ "tags": [
1888
+ "Lists"
1889
+ ],
1890
+ "security": [
1891
+ {
1892
+ "bearerAuth": []
1893
+ }
1894
+ ],
1895
+ "parameters": [
1896
+ {
1897
+ "$ref": "#/components/parameters/ListId"
1898
+ }
1899
+ ],
1900
+ "requestBody": {
1901
+ "description": "The data to update. Only the fields you want to update need to be provided.",
1902
+ "content": {
1903
+ "application/json": {
1904
+ "schema": {
1905
+ "type": "object",
1906
+ "properties": {
1907
+ "name": {
1908
+ "type": "string",
1909
+ "minLength": 1,
1910
+ "maxLength": 40
1911
+ },
1912
+ "description": {
1913
+ "type": "string",
1914
+ "nullable": true,
1915
+ "minLength": 0,
1916
+ "maxLength": 100
1917
+ },
1918
+ "icon": {
1919
+ "type": "string"
1920
+ },
1921
+ "parentId": {
1922
+ "type": "string",
1923
+ "nullable": true
1924
+ },
1925
+ "query": {
1926
+ "type": "string",
1927
+ "minLength": 1
1928
+ }
1929
+ }
1930
+ }
1931
+ }
1932
+ }
1933
+ },
1934
+ "responses": {
1935
+ "200": {
1936
+ "description": "The updated list",
1937
+ "content": {
1938
+ "application/json": {
1939
+ "schema": {
1940
+ "$ref": "#/components/schemas/List"
1941
+ }
1942
+ }
1943
+ }
1944
+ },
1945
+ "404": {
1946
+ "description": "List not found",
1947
+ "content": {
1948
+ "application/json": {
1949
+ "schema": {
1950
+ "type": "object",
1951
+ "properties": {
1952
+ "code": {
1953
+ "type": "string"
1954
+ },
1955
+ "message": {
1956
+ "type": "string"
1957
+ }
1958
+ },
1959
+ "required": [
1960
+ "code",
1961
+ "message"
1962
+ ]
1963
+ }
1964
+ }
1965
+ }
1966
+ }
1967
+ }
1968
+ }
1969
+ },
1970
+ "/lists/{listId}/bookmarks": {
1971
+ "get": {
1972
+ "description": "Get the bookmarks in a list",
1973
+ "summary": "Get a bookmarks in a list",
1974
+ "tags": [
1975
+ "Lists"
1976
+ ],
1977
+ "security": [
1978
+ {
1979
+ "bearerAuth": []
1980
+ }
1981
+ ],
1982
+ "parameters": [
1983
+ {
1984
+ "$ref": "#/components/parameters/ListId"
1985
+ },
1986
+ {
1987
+ "schema": {
1988
+ "type": "number"
1989
+ },
1990
+ "required": false,
1991
+ "name": "limit",
1992
+ "in": "query"
1993
+ },
1994
+ {
1995
+ "schema": {
1996
+ "$ref": "#/components/schemas/Cursor"
1997
+ },
1998
+ "required": false,
1999
+ "name": "cursor",
2000
+ "in": "query"
2001
+ },
2002
+ {
2003
+ "schema": {
2004
+ "type": "boolean",
2005
+ "default": true,
2006
+ "description": "If set to true, bookmark's content will be included in the response. Note, this content can be large for some bookmarks."
2007
+ },
2008
+ "required": false,
2009
+ "description": "If set to true, bookmark's content will be included in the response. Note, this content can be large for some bookmarks.",
2010
+ "name": "includeContent",
2011
+ "in": "query"
2012
+ }
2013
+ ],
2014
+ "responses": {
2015
+ "200": {
2016
+ "description": "Object with list data.",
2017
+ "content": {
2018
+ "application/json": {
2019
+ "schema": {
2020
+ "$ref": "#/components/schemas/PaginatedBookmarks"
2021
+ }
2022
+ }
2023
+ }
2024
+ },
2025
+ "404": {
2026
+ "description": "List not found",
2027
+ "content": {
2028
+ "application/json": {
2029
+ "schema": {
2030
+ "type": "object",
2031
+ "properties": {
2032
+ "code": {
2033
+ "type": "string"
2034
+ },
2035
+ "message": {
2036
+ "type": "string"
2037
+ }
2038
+ },
2039
+ "required": [
2040
+ "code",
2041
+ "message"
2042
+ ]
2043
+ }
2044
+ }
2045
+ }
2046
+ }
2047
+ }
2048
+ }
2049
+ },
2050
+ "/lists/{listId}/bookmarks/{bookmarkId}": {
2051
+ "put": {
2052
+ "description": "Add the bookmarks to a list",
2053
+ "summary": "Add a bookmark to a list",
2054
+ "tags": [
2055
+ "Lists"
2056
+ ],
2057
+ "security": [
2058
+ {
2059
+ "bearerAuth": []
2060
+ }
2061
+ ],
2062
+ "parameters": [
2063
+ {
2064
+ "$ref": "#/components/parameters/ListId"
2065
+ },
2066
+ {
2067
+ "$ref": "#/components/parameters/BookmarkId"
2068
+ }
2069
+ ],
2070
+ "responses": {
2071
+ "204": {
2072
+ "description": "No content - the bookmark was added"
2073
+ },
2074
+ "400": {
2075
+ "description": "Bookmark already in list",
2076
+ "content": {
2077
+ "application/json": {
2078
+ "schema": {
2079
+ "type": "object",
2080
+ "properties": {
2081
+ "code": {
2082
+ "type": "string"
2083
+ },
2084
+ "message": {
2085
+ "type": "string"
2086
+ }
2087
+ },
2088
+ "required": [
2089
+ "code",
2090
+ "message"
2091
+ ]
2092
+ }
2093
+ }
2094
+ }
2095
+ },
2096
+ "404": {
2097
+ "description": "List or bookmark not found",
2098
+ "content": {
2099
+ "application/json": {
2100
+ "schema": {
2101
+ "type": "object",
2102
+ "properties": {
2103
+ "code": {
2104
+ "type": "string"
2105
+ },
2106
+ "message": {
2107
+ "type": "string"
2108
+ }
2109
+ },
2110
+ "required": [
2111
+ "code",
2112
+ "message"
2113
+ ]
2114
+ }
2115
+ }
2116
+ }
2117
+ }
2118
+ }
2119
+ },
2120
+ "delete": {
2121
+ "description": "Remove the bookmarks from a list",
2122
+ "summary": "Remove a bookmark from a list",
2123
+ "tags": [
2124
+ "Lists"
2125
+ ],
2126
+ "security": [
2127
+ {
2128
+ "bearerAuth": []
2129
+ }
2130
+ ],
2131
+ "parameters": [
2132
+ {
2133
+ "$ref": "#/components/parameters/ListId"
2134
+ },
2135
+ {
2136
+ "$ref": "#/components/parameters/BookmarkId"
2137
+ }
2138
+ ],
2139
+ "responses": {
2140
+ "204": {
2141
+ "description": "No content - the bookmark was added"
2142
+ },
2143
+ "400": {
2144
+ "description": "Bookmark already not in list",
2145
+ "content": {
2146
+ "application/json": {
2147
+ "schema": {
2148
+ "type": "object",
2149
+ "properties": {
2150
+ "code": {
2151
+ "type": "string"
2152
+ },
2153
+ "message": {
2154
+ "type": "string"
2155
+ }
2156
+ },
2157
+ "required": [
2158
+ "code",
2159
+ "message"
2160
+ ]
2161
+ }
2162
+ }
2163
+ }
2164
+ },
2165
+ "404": {
2166
+ "description": "List or bookmark not found",
2167
+ "content": {
2168
+ "application/json": {
2169
+ "schema": {
2170
+ "type": "object",
2171
+ "properties": {
2172
+ "code": {
2173
+ "type": "string"
2174
+ },
2175
+ "message": {
2176
+ "type": "string"
2177
+ }
2178
+ },
2179
+ "required": [
2180
+ "code",
2181
+ "message"
2182
+ ]
2183
+ }
2184
+ }
2185
+ }
2186
+ }
2187
+ }
2188
+ }
2189
+ },
2190
+ "/tags": {
2191
+ "get": {
2192
+ "description": "Get all tags",
2193
+ "summary": "Get all tags",
2194
+ "tags": [
2195
+ "Tags"
2196
+ ],
2197
+ "security": [
2198
+ {
2199
+ "bearerAuth": []
2200
+ }
2201
+ ],
2202
+ "responses": {
2203
+ "200": {
2204
+ "description": "Object with all tags data.",
2205
+ "content": {
2206
+ "application/json": {
2207
+ "schema": {
2208
+ "type": "object",
2209
+ "properties": {
2210
+ "tags": {
2211
+ "type": "array",
2212
+ "items": {
2213
+ "$ref": "#/components/schemas/Tag"
2214
+ }
2215
+ }
2216
+ },
2217
+ "required": [
2218
+ "tags"
2219
+ ]
2220
+ }
2221
+ }
2222
+ }
2223
+ }
2224
+ }
2225
+ }
2226
+ },
2227
+ "/tags/{tagId}": {
2228
+ "get": {
2229
+ "description": "Get tag by its id",
2230
+ "summary": "Get a single tag",
2231
+ "tags": [
2232
+ "Tags"
2233
+ ],
2234
+ "security": [
2235
+ {
2236
+ "bearerAuth": []
2237
+ }
2238
+ ],
2239
+ "parameters": [
2240
+ {
2241
+ "$ref": "#/components/parameters/TagId"
2242
+ }
2243
+ ],
2244
+ "responses": {
2245
+ "200": {
2246
+ "description": "Object with list data.",
2247
+ "content": {
2248
+ "application/json": {
2249
+ "schema": {
2250
+ "$ref": "#/components/schemas/Tag"
2251
+ }
2252
+ }
2253
+ }
2254
+ },
2255
+ "404": {
2256
+ "description": "Tag not found",
2257
+ "content": {
2258
+ "application/json": {
2259
+ "schema": {
2260
+ "type": "object",
2261
+ "properties": {
2262
+ "code": {
2263
+ "type": "string"
2264
+ },
2265
+ "message": {
2266
+ "type": "string"
2267
+ }
2268
+ },
2269
+ "required": [
2270
+ "code",
2271
+ "message"
2272
+ ]
2273
+ }
2274
+ }
2275
+ }
2276
+ }
2277
+ }
2278
+ },
2279
+ "delete": {
2280
+ "description": "Delete tag by its id",
2281
+ "summary": "Delete a tag",
2282
+ "tags": [
2283
+ "Tags"
2284
+ ],
2285
+ "security": [
2286
+ {
2287
+ "bearerAuth": []
2288
+ }
2289
+ ],
2290
+ "parameters": [
2291
+ {
2292
+ "$ref": "#/components/parameters/TagId"
2293
+ }
2294
+ ],
2295
+ "responses": {
2296
+ "204": {
2297
+ "description": "No content - the bookmark was deleted"
2298
+ },
2299
+ "404": {
2300
+ "description": "Tag not found",
2301
+ "content": {
2302
+ "application/json": {
2303
+ "schema": {
2304
+ "type": "object",
2305
+ "properties": {
2306
+ "code": {
2307
+ "type": "string"
2308
+ },
2309
+ "message": {
2310
+ "type": "string"
2311
+ }
2312
+ },
2313
+ "required": [
2314
+ "code",
2315
+ "message"
2316
+ ]
2317
+ }
2318
+ }
2319
+ }
2320
+ }
2321
+ }
2322
+ },
2323
+ "patch": {
2324
+ "description": "Update tag by its id",
2325
+ "summary": "Update a tag",
2326
+ "tags": [
2327
+ "Tags"
2328
+ ],
2329
+ "security": [
2330
+ {
2331
+ "bearerAuth": []
2332
+ }
2333
+ ],
2334
+ "parameters": [
2335
+ {
2336
+ "$ref": "#/components/parameters/TagId"
2337
+ }
2338
+ ],
2339
+ "requestBody": {
2340
+ "description": "The data to update. Only the fields you want to update need to be provided.",
2341
+ "content": {
2342
+ "application/json": {
2343
+ "schema": {
2344
+ "type": "object",
2345
+ "properties": {
2346
+ "name": {
2347
+ "type": "string"
2348
+ }
2349
+ }
2350
+ }
2351
+ }
2352
+ }
2353
+ },
2354
+ "responses": {
2355
+ "200": {
2356
+ "description": "The updated tag",
2357
+ "content": {
2358
+ "application/json": {
2359
+ "schema": {
2360
+ "$ref": "#/components/schemas/Tag"
2361
+ }
2362
+ }
2363
+ }
2364
+ },
2365
+ "404": {
2366
+ "description": "Tag not found",
2367
+ "content": {
2368
+ "application/json": {
2369
+ "schema": {
2370
+ "type": "object",
2371
+ "properties": {
2372
+ "code": {
2373
+ "type": "string"
2374
+ },
2375
+ "message": {
2376
+ "type": "string"
2377
+ }
2378
+ },
2379
+ "required": [
2380
+ "code",
2381
+ "message"
2382
+ ]
2383
+ }
2384
+ }
2385
+ }
2386
+ }
2387
+ }
2388
+ }
2389
+ },
2390
+ "/tags/{tagId}/bookmarks": {
2391
+ "get": {
2392
+ "description": "Get the bookmarks with the tag",
2393
+ "summary": "Get a bookmarks with the tag",
2394
+ "tags": [
2395
+ "Tags"
2396
+ ],
2397
+ "security": [
2398
+ {
2399
+ "bearerAuth": []
2400
+ }
2401
+ ],
2402
+ "parameters": [
2403
+ {
2404
+ "$ref": "#/components/parameters/TagId"
2405
+ },
2406
+ {
2407
+ "schema": {
2408
+ "type": "number"
2409
+ },
2410
+ "required": false,
2411
+ "name": "limit",
2412
+ "in": "query"
2413
+ },
2414
+ {
2415
+ "schema": {
2416
+ "$ref": "#/components/schemas/Cursor"
2417
+ },
2418
+ "required": false,
2419
+ "name": "cursor",
2420
+ "in": "query"
2421
+ },
2422
+ {
2423
+ "schema": {
2424
+ "type": "boolean",
2425
+ "default": true,
2426
+ "description": "If set to true, bookmark's content will be included in the response. Note, this content can be large for some bookmarks."
2427
+ },
2428
+ "required": false,
2429
+ "description": "If set to true, bookmark's content will be included in the response. Note, this content can be large for some bookmarks.",
2430
+ "name": "includeContent",
2431
+ "in": "query"
2432
+ }
2433
+ ],
2434
+ "responses": {
2435
+ "200": {
2436
+ "description": "Object with list data.",
2437
+ "content": {
2438
+ "application/json": {
2439
+ "schema": {
2440
+ "$ref": "#/components/schemas/PaginatedBookmarks"
2441
+ }
2442
+ }
2443
+ }
2444
+ },
2445
+ "404": {
2446
+ "description": "Tag not found",
2447
+ "content": {
2448
+ "application/json": {
2449
+ "schema": {
2450
+ "type": "object",
2451
+ "properties": {
2452
+ "code": {
2453
+ "type": "string"
2454
+ },
2455
+ "message": {
2456
+ "type": "string"
2457
+ }
2458
+ },
2459
+ "required": [
2460
+ "code",
2461
+ "message"
2462
+ ]
2463
+ }
2464
+ }
2465
+ }
2466
+ }
2467
+ }
2468
+ }
2469
+ },
2470
+ "/highlights": {
2471
+ "get": {
2472
+ "description": "Get all highlights",
2473
+ "summary": "Get all highlights",
2474
+ "tags": [
2475
+ "Highlights"
2476
+ ],
2477
+ "security": [
2478
+ {
2479
+ "bearerAuth": []
2480
+ }
2481
+ ],
2482
+ "parameters": [
2483
+ {
2484
+ "schema": {
2485
+ "type": "number"
2486
+ },
2487
+ "required": false,
2488
+ "name": "limit",
2489
+ "in": "query"
2490
+ },
2491
+ {
2492
+ "schema": {
2493
+ "$ref": "#/components/schemas/Cursor"
2494
+ },
2495
+ "required": false,
2496
+ "name": "cursor",
2497
+ "in": "query"
2498
+ }
2499
+ ],
2500
+ "responses": {
2501
+ "200": {
2502
+ "description": "Object with all highlights data.",
2503
+ "content": {
2504
+ "application/json": {
2505
+ "schema": {
2506
+ "$ref": "#/components/schemas/PaginatedHighlights"
2507
+ }
2508
+ }
2509
+ }
2510
+ }
2511
+ }
2512
+ },
2513
+ "post": {
2514
+ "description": "Create a new highlight",
2515
+ "summary": "Create a new highlight",
2516
+ "tags": [
2517
+ "Highlights"
2518
+ ],
2519
+ "security": [
2520
+ {
2521
+ "bearerAuth": []
2522
+ }
2523
+ ],
2524
+ "requestBody": {
2525
+ "description": "The highlight to create",
2526
+ "content": {
2527
+ "application/json": {
2528
+ "schema": {
2529
+ "type": "object",
2530
+ "properties": {
2531
+ "bookmarkId": {
2532
+ "type": "string"
2533
+ },
2534
+ "startOffset": {
2535
+ "type": "number"
2536
+ },
2537
+ "endOffset": {
2538
+ "type": "number"
2539
+ },
2540
+ "color": {
2541
+ "type": "string",
2542
+ "enum": [
2543
+ "yellow",
2544
+ "red",
2545
+ "green",
2546
+ "blue"
2547
+ ],
2548
+ "default": "yellow"
2549
+ },
2550
+ "text": {
2551
+ "type": "string",
2552
+ "nullable": true
2553
+ },
2554
+ "note": {
2555
+ "type": "string",
2556
+ "nullable": true
2557
+ }
2558
+ },
2559
+ "required": [
2560
+ "bookmarkId",
2561
+ "startOffset",
2562
+ "endOffset",
2563
+ "text",
2564
+ "note"
2565
+ ]
2566
+ }
2567
+ }
2568
+ }
2569
+ },
2570
+ "responses": {
2571
+ "201": {
2572
+ "description": "The created highlight",
2573
+ "content": {
2574
+ "application/json": {
2575
+ "schema": {
2576
+ "$ref": "#/components/schemas/Highlight"
2577
+ }
2578
+ }
2579
+ }
2580
+ },
2581
+ "400": {
2582
+ "description": "Bad highlight request",
2583
+ "content": {
2584
+ "application/json": {
2585
+ "schema": {
2586
+ "type": "object",
2587
+ "properties": {
2588
+ "code": {
2589
+ "type": "string"
2590
+ },
2591
+ "message": {
2592
+ "type": "string"
2593
+ }
2594
+ },
2595
+ "required": [
2596
+ "code",
2597
+ "message"
2598
+ ]
2599
+ }
2600
+ }
2601
+ }
2602
+ },
2603
+ "404": {
2604
+ "description": "Bookmark not found",
2605
+ "content": {
2606
+ "application/json": {
2607
+ "schema": {
2608
+ "type": "object",
2609
+ "properties": {
2610
+ "code": {
2611
+ "type": "string"
2612
+ },
2613
+ "message": {
2614
+ "type": "string"
2615
+ }
2616
+ },
2617
+ "required": [
2618
+ "code",
2619
+ "message"
2620
+ ]
2621
+ }
2622
+ }
2623
+ }
2624
+ }
2625
+ }
2626
+ }
2627
+ },
2628
+ "/highlights/{highlightId}": {
2629
+ "get": {
2630
+ "description": "Get highlight by its id",
2631
+ "summary": "Get a single highlight",
2632
+ "tags": [
2633
+ "Highlights"
2634
+ ],
2635
+ "security": [
2636
+ {
2637
+ "bearerAuth": []
2638
+ }
2639
+ ],
2640
+ "parameters": [
2641
+ {
2642
+ "$ref": "#/components/parameters/HighlightId"
2643
+ }
2644
+ ],
2645
+ "responses": {
2646
+ "200": {
2647
+ "description": "Object with highlight data.",
2648
+ "content": {
2649
+ "application/json": {
2650
+ "schema": {
2651
+ "$ref": "#/components/schemas/Highlight"
2652
+ }
2653
+ }
2654
+ }
2655
+ },
2656
+ "404": {
2657
+ "description": "Highlight not found",
2658
+ "content": {
2659
+ "application/json": {
2660
+ "schema": {
2661
+ "type": "object",
2662
+ "properties": {
2663
+ "code": {
2664
+ "type": "string"
2665
+ },
2666
+ "message": {
2667
+ "type": "string"
2668
+ }
2669
+ },
2670
+ "required": [
2671
+ "code",
2672
+ "message"
2673
+ ]
2674
+ }
2675
+ }
2676
+ }
2677
+ }
2678
+ }
2679
+ },
2680
+ "delete": {
2681
+ "description": "Delete highlight by its id",
2682
+ "summary": "Delete a highlight",
2683
+ "tags": [
2684
+ "Highlights"
2685
+ ],
2686
+ "security": [
2687
+ {
2688
+ "bearerAuth": []
2689
+ }
2690
+ ],
2691
+ "parameters": [
2692
+ {
2693
+ "$ref": "#/components/parameters/HighlightId"
2694
+ }
2695
+ ],
2696
+ "responses": {
2697
+ "200": {
2698
+ "description": "The deleted highlight",
2699
+ "content": {
2700
+ "application/json": {
2701
+ "schema": {
2702
+ "$ref": "#/components/schemas/Highlight"
2703
+ }
2704
+ }
2705
+ }
2706
+ },
2707
+ "404": {
2708
+ "description": "Highlight not found",
2709
+ "content": {
2710
+ "application/json": {
2711
+ "schema": {
2712
+ "type": "object",
2713
+ "properties": {
2714
+ "code": {
2715
+ "type": "string"
2716
+ },
2717
+ "message": {
2718
+ "type": "string"
2719
+ }
2720
+ },
2721
+ "required": [
2722
+ "code",
2723
+ "message"
2724
+ ]
2725
+ }
2726
+ }
2727
+ }
2728
+ }
2729
+ }
2730
+ },
2731
+ "patch": {
2732
+ "description": "Update highlight by its id",
2733
+ "summary": "Update a highlight",
2734
+ "tags": [
2735
+ "Highlights"
2736
+ ],
2737
+ "security": [
2738
+ {
2739
+ "bearerAuth": []
2740
+ }
2741
+ ],
2742
+ "parameters": [
2743
+ {
2744
+ "$ref": "#/components/parameters/HighlightId"
2745
+ }
2746
+ ],
2747
+ "requestBody": {
2748
+ "description": "The data to update. Only the fields you want to update need to be provided.",
2749
+ "content": {
2750
+ "application/json": {
2751
+ "schema": {
2752
+ "type": "object",
2753
+ "properties": {
2754
+ "color": {
2755
+ "type": "string",
2756
+ "enum": [
2757
+ "yellow",
2758
+ "red",
2759
+ "green",
2760
+ "blue"
2761
+ ]
2762
+ }
2763
+ }
2764
+ }
2765
+ }
2766
+ }
2767
+ },
2768
+ "responses": {
2769
+ "200": {
2770
+ "description": "The updated highlight",
2771
+ "content": {
2772
+ "application/json": {
2773
+ "schema": {
2774
+ "$ref": "#/components/schemas/Highlight"
2775
+ }
2776
+ }
2777
+ }
2778
+ },
2779
+ "404": {
2780
+ "description": "Highlight not found",
2781
+ "content": {
2782
+ "application/json": {
2783
+ "schema": {
2784
+ "type": "object",
2785
+ "properties": {
2786
+ "code": {
2787
+ "type": "string"
2788
+ },
2789
+ "message": {
2790
+ "type": "string"
2791
+ }
2792
+ },
2793
+ "required": [
2794
+ "code",
2795
+ "message"
2796
+ ]
2797
+ }
2798
+ }
2799
+ }
2800
+ }
2801
+ }
2802
+ }
2803
+ },
2804
+ "/users/me": {
2805
+ "get": {
2806
+ "description": "Returns info about the current user",
2807
+ "summary": "Get current user info",
2808
+ "tags": [
2809
+ "Users"
2810
+ ],
2811
+ "security": [
2812
+ {
2813
+ "bearerAuth": []
2814
+ }
2815
+ ],
2816
+ "responses": {
2817
+ "200": {
2818
+ "description": "Object with user data.",
2819
+ "content": {
2820
+ "application/json": {
2821
+ "schema": {
2822
+ "type": "object",
2823
+ "properties": {
2824
+ "id": {
2825
+ "type": "string"
2826
+ },
2827
+ "name": {
2828
+ "type": "string",
2829
+ "nullable": true
2830
+ },
2831
+ "email": {
2832
+ "type": "string",
2833
+ "nullable": true
2834
+ }
2835
+ },
2836
+ "required": [
2837
+ "id"
2838
+ ]
2839
+ }
2840
+ }
2841
+ }
2842
+ }
2843
+ }
2844
+ }
2845
+ },
2846
+ "/users/me/stats": {
2847
+ "get": {
2848
+ "description": "Returns stats about the current user",
2849
+ "summary": "Get current user stats",
2850
+ "tags": [
2851
+ "Users"
2852
+ ],
2853
+ "security": [
2854
+ {
2855
+ "bearerAuth": []
2856
+ }
2857
+ ],
2858
+ "responses": {
2859
+ "200": {
2860
+ "description": "Object with user stats.",
2861
+ "content": {
2862
+ "application/json": {
2863
+ "schema": {
2864
+ "type": "object",
2865
+ "properties": {
2866
+ "numBookmarks": {
2867
+ "type": "number"
2868
+ },
2869
+ "numFavorites": {
2870
+ "type": "number"
2871
+ },
2872
+ "numArchived": {
2873
+ "type": "number"
2874
+ },
2875
+ "numTags": {
2876
+ "type": "number"
2877
+ },
2878
+ "numLists": {
2879
+ "type": "number"
2880
+ },
2881
+ "numHighlights": {
2882
+ "type": "number"
2883
+ }
2884
+ },
2885
+ "required": [
2886
+ "numBookmarks",
2887
+ "numFavorites",
2888
+ "numArchived",
2889
+ "numTags",
2890
+ "numLists",
2891
+ "numHighlights"
2892
+ ]
2893
+ }
2894
+ }
2895
+ }
2896
+ }
2897
+ }
2898
+ }
2899
+ }
2900
+ }
2901
+ }