This repository contains an implementation of a Blog API using NodeJS, Typescript, and Prisma.
- CRUD operations for Blog Posts and
- Liking a Blog Post
- Clone the repository
- Install dependencies by running
yarn install
- Start the application by running
yarn start
The following endpoints are available:
POST /posts/create
: Create a new Blog PostPOST /posts/createPostAndComments
: Create a new Blog Post that allows CommentsGET /posts/getall
: Get all Blog PostsGET /posts/get/:id
: Get a Blog Post by IDPUT /posts/update/:id
: Update a Blog Post by IDDELETE /posts/delete/:id
: Delete a Blog Post by IDDELETE /posts/deleteall
: Delete all Blog PostsPOST /posts/like
: Like a Blog Post
To use this application, you will need the following:
- NodeJS
- NPM
- Typescript
- Prisma
If you find any bugs or issues with this repository, feel free to open an issue or submit a pull request.
This project was developed as a demonstration of NodeJS, Typescript, and Prisma. To read the Article, see this blog post.