mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-07-28 17:02:04 +03:00
Filled out base Book API endpoints, added example responses
This commit is contained in:
10
dev/api/responses/books-create.json
Normal file
10
dev/api/responses/books-create.json
Normal file
@ -0,0 +1,10 @@
|
||||
{
|
||||
"name": "My new book",
|
||||
"description": "This is a book created via the API",
|
||||
"created_by": 1,
|
||||
"updated_by": 1,
|
||||
"slug": "my-new-book",
|
||||
"updated_at": "2020-01-12 14:05:11",
|
||||
"created_at": "2020-01-12 14:05:11",
|
||||
"id": 15
|
||||
}
|
27
dev/api/responses/books-index.json
Normal file
27
dev/api/responses/books-index.json
Normal file
@ -0,0 +1,27 @@
|
||||
{
|
||||
"data": [
|
||||
{
|
||||
"id": 1,
|
||||
"name": "BookStack User Guide",
|
||||
"slug": "bookstack-user-guide",
|
||||
"description": "This is a general guide on using BookStack on a day-to-day basis.",
|
||||
"created_at": "2019-05-05 21:48:46",
|
||||
"updated_at": "2019-12-11 20:57:31",
|
||||
"created_by": 1,
|
||||
"updated_by": 1,
|
||||
"image_id": 3
|
||||
},
|
||||
{
|
||||
"id": 2,
|
||||
"name": "Inventore inventore quia voluptatem.",
|
||||
"slug": "inventore-inventore-quia-voluptatem",
|
||||
"description": "Veniam nihil voluptas enim laborum corporis quos sint. Ab rerum voluptas ut iste voluptas magni quibusdam ut. Amet omnis enim voluptate neque facilis.",
|
||||
"created_at": "2019-05-05 22:10:14",
|
||||
"updated_at": "2019-12-11 20:57:23",
|
||||
"created_by": 4,
|
||||
"updated_by": 3,
|
||||
"image_id": 34
|
||||
}
|
||||
],
|
||||
"total": 14
|
||||
}
|
47
dev/api/responses/books-read.json
Normal file
47
dev/api/responses/books-read.json
Normal file
@ -0,0 +1,47 @@
|
||||
{
|
||||
"id": 16,
|
||||
"name": "My own book",
|
||||
"slug": "my-own-book",
|
||||
"description": "This is my own little book",
|
||||
"created_at": "2020-01-12 14:09:59",
|
||||
"updated_at": "2020-01-12 14:11:51",
|
||||
"created_by": {
|
||||
"id": 1,
|
||||
"name": "Admin",
|
||||
"created_at": "2019-05-05 21:15:13",
|
||||
"updated_at": "2019-12-16 12:18:37",
|
||||
"image_id": 48
|
||||
},
|
||||
"updated_by": {
|
||||
"id": 1,
|
||||
"name": "Admin",
|
||||
"created_at": "2019-05-05 21:15:13",
|
||||
"updated_at": "2019-12-16 12:18:37",
|
||||
"image_id": 48
|
||||
},
|
||||
"image_id": 452,
|
||||
"tags": [
|
||||
{
|
||||
"id": 13,
|
||||
"entity_id": 16,
|
||||
"entity_type": "BookStack\\Book",
|
||||
"name": "Category",
|
||||
"value": "Guide",
|
||||
"order": 0,
|
||||
"created_at": "2020-01-12 14:11:51",
|
||||
"updated_at": "2020-01-12 14:11:51"
|
||||
}
|
||||
],
|
||||
"cover": {
|
||||
"id": 452,
|
||||
"name": "sjovall_m117hUWMu40.jpg",
|
||||
"url": "http:\/\/bookstack.local\/uploads\/images\/cover_book\/2020-01\/sjovall_m117hUWMu40.jpg",
|
||||
"created_at": "2020-01-12 14:11:51",
|
||||
"updated_at": "2020-01-12 14:11:51",
|
||||
"created_by": 1,
|
||||
"updated_by": 1,
|
||||
"path": "\/uploads\/images\/cover_book\/2020-01\/sjovall_m117hUWMu40.jpg",
|
||||
"type": "cover_book",
|
||||
"uploaded_to": 16
|
||||
}
|
||||
}
|
11
dev/api/responses/books-update.json
Normal file
11
dev/api/responses/books-update.json
Normal file
@ -0,0 +1,11 @@
|
||||
{
|
||||
"id": 16,
|
||||
"name": "My own book",
|
||||
"slug": "my-own-book",
|
||||
"description": "This is my own little book - updated",
|
||||
"created_at": "2020-01-12 14:09:59",
|
||||
"updated_at": "2020-01-12 14:16:10",
|
||||
"created_by": 1,
|
||||
"updated_by": 1,
|
||||
"image_id": 452
|
||||
}
|
Reference in New Issue
Block a user