docs: add Carousel dashboard implementation plan

This commit is contained in:
john-okeefe committed 2026-02-17 17:00:46 -05:00
1 parent fce16b53f7
commit 96730d9475
407 files changed
+10834 -10983

No files matched your search

-61
View File
@@ -1,61 +0,0 @@
meta {
name: KOReader Get Book Metadata
type: http
seq: 2
}
get {
url: {{base_url}}/api/sync/koreader/metadata/{{book_uuid}}
body: none
auth: inherit
}
headers {
Authorization: Bearer {{device_token}}
Content-Type: application/json
}
script:post-response {
function onResponse(res) {
if (res.getStatus() === 200) {
const body = res.getBody();
tests['Status is 200'] = true;
tests['Has UUID'] = body.uuid !== null;
tests['Has title'] = body.title !== null;
tests['Has progress'] = body.progress !== null;
}
}
onResponse(res);
}
settings {
encodeUrl: true
timeout: 0
}
docs {
## KOReader Get Book Metadata
Retrieves metadata for a specific book from the KOReader sync endpoint.
**Method:** GET
**Endpoint:** /api/sync/koreader/metadata/{book_uuid}
**Authentication:** Bearer token (device token)
**Path Parameters:**
- `book_uuid` (string): Book UUID
**Response:**
- `uuid` (string): Book UUID
- `title` (string): Book title
- `progress` (object): Reading progress data
- `metadata` (object): Additional book metadata
**Status Codes:**
- 200: Success
- 401: Unauthorized
- 404: Book not found
- 500: Internal server error
}
-55
View File
@@ -1,55 +0,0 @@
meta {
name: KOReader Get Library
type: http
seq: 3
}
get {
url: {{base_url}}/api/sync/koreader/library
body: none
auth: inherit
}
headers {
Authorization: Bearer {{device_token}}
Content-Type: application/json
}
script:post-response {
function onResponse(res) {
if (res.getStatus() === 200) {
const body = res.getBody();
tests['Status is 200'] = res.getStatus() === 200;
tests['Has library_sync'] = body.library_sync != null;
tests('Total books >= 0', body.total_books >= 0);
}
}
onResponse(res);
}
settings {
encodeUrl: true
timeout: 0
}
docs {
## KOReader Get Library
Retrieves the user's library for KOReader sync operations.
**Method:** GET
**Endpoint:** /api/sync/koreader/library
**Authentication:** Bearer token (device token)
**Response:**
- `library_sync` (object): Library sync data
- `total_books` (number): Total number of books
- `books` (array): Array of book objects
**Status Codes:**
- 200: Success
- 401: Unauthorized
- 500: Internal server error
}
@@ -1,86 +0,0 @@
meta {
name: KOReader Sync Annotations - Per-Book SHA-256
type: http
seq: 4
}
post {
url: {{base_url}}/api/v1/koreader/sync/bookmarks
body: json
auth: inherit
}
headers {
Authorization: Bearer {{koreader_device_token}}
Content-Type: application/json
}
body:json {
{
"book_uuid": "{{book_uuid}}",
"highlights": [
{
"text": "Quote from book 1",
"pos0": "/6/4[chap1ref]!/4/2/1:0",
"pos1": "/6/4[chap1ref]!/4/2/1:50",
"color": "#ffff00",
"page": 10,
"book_sha256": "{{book_sha256}}"
},
{
"text": "Quote from book 2 (different book)",
"pos0": "/6/4[chap1ref]!/4/2/1:0",
"pos1": "/6/4[chap1ref]!/4/2/1:50",
"color": "#00ff00",
"page": 15,
"book_sha256": "{{another_book_sha256}}"
}
]
}
}
script:post-response {
function onResponse(res) {
if (res.getStatus() === 200) {
const body = res.getBody();
tests('Highlights synced >= 0', body.highlights_synced >= 0);
}
}
onResponse(res);
}
settings {
encodeUrl: true
timeout: 0
}
docs {
## KOReader Sync Annotations - Per-Book SHA-256
Synchronizes annotations (highlights) from KOReader with per-annotation SHA-256 hashes for multi-book sync.
**Method:** POST
**Endpoint:** /api/v1/koreader/sync/bookmarks
**Authentication:** Bearer token (KOReader device token)
**Request Body:**
- `book_uuid` (string): Primary book UUID
- `highlights` (array): Array of highlight objects
- `text` (string): Highlighted text
- `pos0`, `pos1` (string): EPUB CFI positions
- `color` (string): Highlight color (hex)
- `page` (number): Page number
- `book_sha256` (string): SHA-256 hash for this specific book
**Response:**
- `highlights_synced` (number): Number of highlights synced
**Status Codes:**
- 200: Success
- 401: Unauthorized
- 500: Internal server error
**Note:** Each highlight can include its own book_sha256, allowing annotations from multiple books in a single request.
}
@@ -1,90 +0,0 @@
meta {
name: KOReader Sync Bookmarks - SHA-256
type: http
seq: 3
}
post {
url: {{base_url}}/api/v1/koreader/sync/bookmarks
body: json
auth: inherit
}
headers {
Authorization: Bearer {{koreader_device_token}}
Content-Type: application/json
}
body:json {
{
"book_sha256": "{{book_sha256}}",
"bookmarks": [
{
"text": "Important passage about chapter 3",
"pos0": "/6/4[chap3ref]!/4/2/1:0",
"page": 45,
"type": "bookmark"
}
],
"notes": [
{
"notes": "My note about this section",
"pos0": "/6/4[chap3ref]!/4/2/1:100",
"page": 47,
"text": "Quoted text from the book"
}
],
"highlights": [
{
"text": "This is highlighted text",
"pos0": "/6/4[chap3ref]!/4/2/1:50",
"pos1": "/6/4[chap3ref]!/4/2/1:100",
"color": "#ffff00",
"page": 50
}
]
}
}
script:post-response {
function onResponse(res) {
if (res.getStatus() === 200) {
const body = res.getBody();
tests('Sync completed', body.sync_status === "completed");
tests('Total synced >= 0', body.total_synced >= 0);
}
}
onResponse(res);
}
settings {
encodeUrl: true
timeout: 0
}
docs {
## KOReader Sync Bookmarks - SHA-256
Synchronizes bookmarks, notes, and highlights from KOReader using SHA-256 hash for book identification.
**Method:** POST
**Endpoint:** /api/v1/koreader/sync/bookmarks
**Authentication:** Bearer token (KOReader device token)
**Request Body:**
- `book_sha256` (string): SHA-256 hash of book file
- `bookmarks` (array): Array of bookmarks
- `notes` (array): Array of notes
- `highlights` (array): Array of highlights
**Response:**
- `sync_status` (string): Sync status
- `total_synced` (number): Total items synced
**Status Codes:**
- 200: Success
- 401: Unauthorized
- 500: Internal server error
}
-112
View File
@@ -1,112 +0,0 @@
meta {
name: KOReader Sync Bookmarks
type: http
seq: 4
}
post {
url: {{base_url}}/api/sync/koreader/bookmarks
body: json
auth: inherit
}
headers {
Authorization: Bearer {{device_token}}
Content-Type: application/json
}
body:json {
{
"book_uuid": "{{book_uuid}}",
"bookmarks": [
{
"chapter": 3,
"datetime": "2026-01-30T19:55:00Z",
"notes": "Bookmarked text",
"pos0": "epubcfi(/6/4/2:15)",
"pos1": "epubcfi(/6/4/2:20)",
"page": 45,
"text": "This is important",
"type": "highlight",
"percentage": 0.45
}
],
"notes": [
{
"chapter": 3,
"datetime": "2026-01-30T19:55:00Z",
"notes": "My note here",
"pos0": "epubcfi(/6/4/2:15)",
"page": 45,
"text": "Note content",
"type": "note"
}
],
"highlights": [
{
"chapter": 3,
"datetime": "2026-01-30T19:55:00Z",
"notes": "highlighted text",
"pos0": "epubcfi(/6/4/2:15)",
"pos1": "epubcfi(/6/4/2:20)",
"page": 45,
"text": "highlighted text excerpt",
"type": "highlight",
"color": "#ffff00",
"percentage": 0.45
}
]
}
}
script:post-response {
function onResponse(res) {
if (res.getStatus() === 200) {
const body = res.getBody();
tests['Sync completed'] = body.sync_status === "completed";
tests('Items synced >= 0', body.total_synced >= 0);
}
}
onResponse(res);
}
settings {
encodeUrl: true
timeout: 0
}
docs {
## KOReader Sync Bookmarks
Synchronizes bookmarks, notes, and highlights from a KOReader device.
**Method:** POST
**Endpoint:** /api/sync/koreader/bookmarks
**Authentication:** Bearer token (device token)
**Request Body:**
- `book_uuid` (string): Book UUID
- `bookmarks` (array): Array of bookmark objects
- `notes` (array): Array of note objects
- `highlights` (array): Array of highlight objects
Each object includes:
- `chapter` (number): Chapter number
- `datetime` (string): ISO 8601 timestamp
- `text` (string): Highlighted/bookmarked text
- `pos0`, `pos1` (string): EPUB CFI positions
- `page` (number): Page number
- `type` (string): Type (highlight, bookmark, note)
- `percentage` (number): Position in book (0-1)
**Response:**
- `sync_status` (string): Sync status (completed, partial)
- `total_synced` (number): Number of items synced
**Status Codes:**
- 200: Success
- 401: Unauthorized
- 500: Internal server error
}
@@ -1,76 +0,0 @@
meta {
name: KOReader Sync Progress - SHA-256 Only
type: http
seq: 2
}
post {
url: {{base_url}}/api/v1/koreader/sync/progress
body: json
auth: inherit
}
headers {
Authorization: Bearer {{koreader_device_token}}
Content-Type: application/json
}
body:json {
{
"sync_mode": "immediate",
"books": [
{
"sha256": "{{book_sha256}}",
"file_path": "/mnt/onboard/Unknown%20Book.epub",
"percentage": 0.45,
"page": 89,
"total_pages": 200
}
]
}
}
script:post-response {
function onResponse(res) {
tests('Status is 200 or 202', res.getStatus() === 200 || res.getStatus() === 202);
}
onResponse(res);
}
settings {
encodeUrl: true
timeout: 0
}
docs {
## KOReader Sync Progress - SHA-256 Only
Synchronizes reading progress using only SHA-256 hash for book identification (when UUID is not available).
**Method:** POST
**Endpoint:** /api/v1/koreader/sync/progress
**Authentication:** Bearer token (KOReader device token)
**Request Body:**
- `sync_mode` (string): Sync mode (immediate, deferred)
- `books` (array): Array of book progress objects
- `sha256` (string): SHA-256 hash of book file
- `file_path` (string): Path to book file
- `percentage` (number): Progress percentage
- `page` (number): Current page
- `total_pages` (number): Total pages
**Response:**
- `sync_status` (string): Sync status
- `books_synced` (number): Number of books synced
**Status Codes:**
- 200: Success
- 202: Accepted
- 401: Unauthorized
- 500: Internal server error
**Note:** Use this when book UUID is not available, falling back to SHA-256 hash for identification.
}
@@ -1,91 +0,0 @@
meta {
name: KOReader Sync Progress - SHA-256
type: http
seq: 1
}
post {
url: {{base_url}}/api/v1/koreader/sync/progress
body: json
auth: inherit
}
headers {
Authorization: Bearer {{koreader_device_token}}
Content-Type: application/json
}
body:json {
{
"sync_mode": "immediate",
"books": [
{
"uuid": "{{book_uuid}}",
"sha256": "{{book_sha256}}",
"file_path": "/mnt/onboard/The%20Hobbit.epub",
"percentage": 0.65,
"chapter": 5,
"page": 142,
"total_pages": 310,
"epubcfi": "/6/4[chap1ref]!/4/2/1:0",
"last_read": "2026-01-31T12:00:00Z",
"title": "The Hobbit",
"authors": ["J.R.R. Tolkien"]
}
]
}
}
script:post-response {
function onResponse(res) {
if (res.getStatus() === 200 || res.getStatus() === 202) {
const body = res.getBody();
tests['Status accepted'] = res.getStatus() === 200 || res.getStatus() === 202;
tests('Has sync_status', body.sync_status !== undefined);
tests('Books synced >= 0', body.books_synced >= 0);
}
}
onResponse(res);
}
settings {
encodeUrl: true
timeout: 0
}
docs {
## KOReader Sync Progress - SHA-256
Synchronizes reading progress from a KOReader device using SHA-256 book hash for identification.
**Method:** POST
**Endpoint:** /api/v1/koreader/sync/progress
**Authentication:** Bearer token (KOReader device token)
**Request Body:**
- `sync_mode` (string): Sync mode (immediate, deferred)
- `books` (array): Array of book progress objects
- `uuid` (string): Book UUID
- `sha256` (string): SHA-256 hash of book file for identification
- `file_path` (string): Path to book file on device
- `percentage` (number): Progress percentage (0-1)
- `chapter` (number): Current chapter
- `page` (number): Current page
- `total_pages` (number): Total pages
- `epubcfi` (string): EPUB location
- `last_read` (string): ISO 8601 timestamp
- `title` (string): Book title
- `authors` (array): List of authors
**Response:**
- `sync_status` (string): Sync status
- `books_synced` (number): Number of books synced
**Status Codes:**
- 200: Success
- 202: Accepted - processing
- 401: Unauthorized
- 500: Internal server error
}
-98
View File
@@ -1,98 +0,0 @@
meta {
name: KOReader Sync Progress
type: http
seq: 1
}
post {
url: {{base_url}}/api/sync/koreader/progress
body: json
auth: inherit
}
headers {
Authorization: Bearer {{device_token}}
Content-Type: application/json
}
body:json {
{
"library_id": null,
"books": [
{
"uuid": "{{book_uuid}}",
"title": "Test Book",
"authors": ["Test Author"],
"progress": 0.45,
"percentage": 0.45,
"last_read": "2026-01-30T20:00:00Z",
"chapter": 5,
"character": 15432,
"epubcfi": "epubcfi(/6/4/2:15)",
"page": 89,
"total_pages": 200
}
],
"sync_mode": "immediate",
"device_info": {
"koreader_version": "2024.01",
"device_model": "kindle-paperwhite-5"
}
}
}
script:post-response {
function onResponse(res) {
if (res.getStatus() === 202) {
const body = res.getBody();
tests['Status is 202'] = res.getStatus() === 202;
tests['Sync status accepted'] = body.sync_status === "accepted";
tests('Books synced >= 0', body.books_synced >= 0);
}
}
onResponse(res);
}
settings {
encodeUrl: true
timeout: 0
}
docs {
## KOReader Sync Progress
Synchronizes reading progress from a KOReader device to the Bookhoard server.
**Method:** POST
**Endpoint:** /api/sync/koreader/progress
**Authentication:** Bearer token (device token)
**Request Body:**
- `library_id` (string, optional): Library UUID
- `books` (array): Array of book progress objects
- `uuid` (string): Book UUID
- `title` (string): Book title
- `authors` (array): List of authors
- `progress` (number): Progress value
- `percentage` (number): Percentage complete (0-1)
- `last_read` (string): ISO 8601 timestamp
- `chapter` (number): Current chapter
- `epubcfi` (string): EPUB Canonical Fragment Identifier
- `page` (number): Current page
- `total_pages` (number): Total pages
- `sync_mode` (string): Sync mode (immediate, deferred)
- `device_info` (object): Device information
- `koreader_version` (string): KOReader version
- `device_model` (string): Device model identifier
**Response:**
- `sync_status` (string): Sync status (accepted, processing)
- `books_synced` (number): Number of books synced
**Status Codes:**
- 202: Accepted - sync queued
- 401: Unauthorized
- 500: Internal server error
}