Skip to content

Commit 2753e7a

Browse files
committed
Add endpoints in etc
1 parent 545eefe commit 2753e7a

File tree

3 files changed

+66
-0
lines changed

3 files changed

+66
-0
lines changed

etc/endpoints/backoffice_backend.http

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# List of books
2+
GET http://localhost:8040/books
3+
###
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# Get Aliases
2+
GET http://localhost:9200/_aliases
3+
###
4+
5+
# mapping of backoffice_books
6+
GET http://localhost:9200/backoffice_books
7+
###
8+
9+
# search all books
10+
GET http://localhost:9200/backoffice_books/_search
11+
###

etc/endpoints/librarify_backend.http

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
# Health Check
2+
GET http://localhost:8030/health-check
3+
###
4+
5+
# Create a new category
6+
PUT http://localhost:8030/categories/6539ae8b-3e76-4e2a-848f-46da240921ec
7+
Content-Type: application/json
8+
9+
{
10+
"name": "PHP"
11+
}
12+
13+
###
14+
15+
# Create a new author
16+
PUT http://localhost:8030/authors/2493201f-195d-3b9d-b339-45a8ff81d594
17+
Content-Type: application/json
18+
19+
{
20+
"name": "Carlos Perez Sanchez"
21+
}
22+
23+
###
24+
25+
# Create a new book
26+
PUT http://localhost:8030/books/54b66772-4380-44e6-9083-cd48b9e9ea99
27+
Content-Type: application/json
28+
29+
{
30+
"title": "PHP Microservices",
31+
"description": "PHP Microservices",
32+
"score": 1,
33+
"authors": [
34+
"2493201f-195d-3b9d-b339-45a8ff81d594"
35+
],
36+
"categories": [
37+
"6539ae8b-3e76-4e2a-848f-46da240921ec"
38+
]
39+
}
40+
41+
###
42+
43+
# Login
44+
POST http://localhost:8030/login
45+
Content-Type: application/json
46+
47+
{
48+
"username": "serodas",
49+
"password": "gav739hBPq2vFp8Xlx1KOJdhLaa5YInM"
50+
}
51+
52+
###

0 commit comments

Comments
 (0)