Skip to content

Latest commit

 

History

History
41 lines (33 loc) · 930 Bytes

File metadata and controls

41 lines (33 loc) · 930 Bytes

rest-api-node

Rest API in Node with SQLite. It is a basic blog Rest-API which has database table to store blog post data and categories and their relationships.

Start Server

npm run start

API Reference.

GET /posts

To get list of all posts.

$ curl http://localhost:8080/posts

GET /posts/<id>

To get one single post.

$ curl http://localhost:8080/posts/1

POST /posts

To create a new post.

$ curl -X POST http://localhost:8080/posts -d '{"postTitle": "New Post Title", "postContent": "Hello World!!"}'

Built With

Author

License

This project is licensed under the MIT License