]> BookStack Code Mirror - bookstack/blobdiff - dev/api/responses/search-all.json
respective book and chapter structure added.
[bookstack] / dev / api / responses / search-all.json
index bb45b7959033eeb159436c8af6fc275fd6b8a4b3..f60a12f750d68d39e484bbc60512153e5e160f37 100644 (file)
@@ -1,72 +1,92 @@
 {
-  "data": [
-    {
-      "id": 84,
-      "book_id": 1,
-      "slug": "a-chapter-for-cats",
-      "name": "A chapter for cats",
-      "created_at": "2021-11-14T15:57:35.000000Z",
-      "updated_at": "2021-11-14T15:57:35.000000Z",
-      "type": "chapter",
-      "url": "https://example.com/books/my-book/chapter/a-chapter-for-cats",
-      "book_title": "Cats",
-      "preview_html": {
-        "name": "A chapter for <strong>cats</strong>",
-        "content": "...once a bunch of <strong>cats</strong> named tony...behaviour of <strong>cats</strong> is unsuitable"
-      },
-      "tags": []
-    },
-    {
-      "name": "The hows and whys of cats",
-      "id": 396,
-      "slug": "the-hows-and-whys-of-cats",
-      "book_id": 1,
-      "chapter_id": 75,
-      "draft": false,
-      "template": false,
-      "created_at": "2021-05-15T16:28:10.000000Z",
-      "updated_at": "2021-11-14T15:56:49.000000Z",
-      "type": "page",
-      "url": "https://example.com/books/my-book/page/the-hows-and-whys-of-cats",
-      "book_title": "Cats",
-      "chapter_title": "A chapter for cats",
-      "preview_html": {
-        "name": "The hows and whys of <strong>cats</strong>",
-        "content": "...people ask why <strong>cats</strong>? but there are...the reason that <strong>cats</strong> are fast are due to..."
-      },
-      "tags": [
+    "data": [
         {
-          "name": "Animal",
-          "value": "Cat",
-          "order": 0
+            "id": 84,
+            "book_id": 1,
+            "slug": "a-chapter-for-cats",
+            "name": "A chapter for cats",
+            "created_at": "2021-11-14T15:57:35.000000Z",
+            "updated_at": "2021-11-14T15:57:35.000000Z",
+            "type": "chapter",
+            "url": "https://example.com/books/my-book/chapter/a-chapter-for-cats",
+            "book": {
+                "id": 1,
+                "name": "Cats",
+                "slug": "cats"
+            },
+            "preview_html": {
+                "name": "A chapter for <strong>cats</strong>",
+                "content": "...once a bunch of <strong>cats</strong> named tony...behaviour of <strong>cats</strong> is unsuitable"
+            },
+            "tags": []
         },
         {
-          "name": "Category",
-          "value": "Top Content",
-          "order": 0
+            "name": "The hows and whys of cats",
+            "id": 396,
+            "slug": "the-hows-and-whys-of-cats",
+            "book_id": 1,
+            "chapter_id": 75,
+            "draft": false,
+            "template": false,
+            "created_at": "2021-05-15T16:28:10.000000Z",
+            "updated_at": "2021-11-14T15:56:49.000000Z",
+            "type": "page",
+            "url": "https://example.com/books/my-book/page/the-hows-and-whys-of-cats",
+            "book": {
+                "id": 1,
+                "name": "Cats",
+                "slug": "cats"
+            },
+            "chapter": {
+                "id": 84,
+                "name": "A chapter for cats",
+                "slug": "a-chapter-for-cats"
+            },
+            "preview_html": {
+                "name": "The hows and whys of <strong>cats</strong>",
+                "content": "...people ask why <strong>cats</strong>? but there are...the reason that <strong>cats</strong> are fast are due to..."
+            },
+            "tags": [
+                {
+                    "name": "Animal",
+                    "value": "Cat",
+                    "order": 0
+                },
+                {
+                    "name": "Category",
+                    "value": "Top Content",
+                    "order": 0
+                }
+            ]
+        },
+        {
+            "name": "How advanced are cats?",
+            "id": 362,
+            "slug": "how-advanced-are-cats",
+            "book_id": 13,
+            "chapter_id": 73,
+            "draft": false,
+            "template": false,
+            "created_at": "2020-11-29T21:55:07.000000Z",
+            "updated_at": "2021-11-14T16:02:39.000000Z",
+            "type": "page",
+            "url": "https://example.com/books/my-book/page/how-advanced-are-cats",
+            "book": {
+                "id": 1,
+                "name": "Cats",
+                "slug": "cats"
+            },
+            "chapter": {
+                "id": 84,
+                "name": "A chapter for cats",
+                "slug": "a-chapter-for-cats"
+            },
+            "preview_html": {
+                "name": "How advanced are <strong>cats</strong>?",
+                "content": "<strong>cats</strong> are some of the most advanced animals in the world."
+            },
+            "tags": []
         }
-      ]
-    },
-    {
-      "name": "How advanced are cats?",
-      "id": 362,
-      "slug": "how-advanced-are-cats",
-      "book_id": 13,
-      "chapter_id": 73,
-      "draft": false,
-      "template": false,
-      "created_at": "2020-11-29T21:55:07.000000Z",
-      "updated_at": "2021-11-14T16:02:39.000000Z",
-      "type": "page",
-      "url": "https://example.com/books/my-book/page/how-advanced-are-cats",
-      "book_title": "Cats",
-      "chapter_title": "A chapter for cats",
-      "preview_html": {
-        "name": "How advanced are <strong>cats</strong>?",
-        "content": "<strong>cats</strong> are some of the most advanced animals in the world."
-      },
-      "tags": []
-    }
-  ],
-  "total": 3
+    ],
+    "total": 3
 }