A progressive Node.js framework for building efficient and scalable server-side applications.
Nest framework TypeScript starter repository.
Nest REST APIs Medium clone
$ npm install
# development
$ npm run start
# watch mode
$ npm run start:dev
# production mode
$ npm run start:prod
# generate migration
$ npm run db:create
# migrate
$ npm run db:migrate
# drop migration
$ npm run db:drop
# seed data
$ npm run db:seed
# unit tests
$ npm run test
# e2e tests
$ npm run test:e2e
# test coverage
$ npm run test:cov
Get /articles?tag={tag}&author={author}&favorited={favorited}&limit={limit}&offset={offset}
Accept: application/json
Content-Type: application/json
Get /articles/feed?limit={limit}&offset={offset}
Accept: application/json
Content-Type: application/json
Post /articles
Accept: application/json
Content-Type: application/json
{
"title" : "NestJs authentication with OAuth2",
"description" : "Sample Authntication for NestJs project",
"body": "Some article body",
"tagList": ["NestJs", "OAuth2", "rest-api", "Authentication"]
}
Get /articles/{slug}
Accept: application/json
Content-Type: application/json
Delete /articles/{slug}
Accept: application/json
Content-Type: application/json
Put /articles/{slug}
Accept: application/json
Content-Type: application/json
{
"title" : "NestJs authentication with OAuth2",
"description" : "Sample Authntication for NestJs project",
"body": "Some article body",
"tagList": ["NestJs", "OAuth2", "rest-api", "Authentication"]
}
Post /articles/{slug}/favorite
Accept: application/json
Content-Type: application/json
Delete /articles/{slug}/favorite
Accept: application/json
Content-Type: application/json
Post /articles/{slug}/comments
Accept: application/json
Content-Type: application/json
{
"body": "Some comment body",
}
Delete /articles/{slug}/comments/{commentId}
Accept: application/json
Content-Type: application/json
{
"body": "Some comment body",
}
Get /profiles/{username}
Accept: application/json
Content-Type: application/json
Post /profiles/{username}/follow
Accept: application/json
Content-Type: application/json
Delete /profiles/{username}/follow
Accept: application/json
Content-Type: application/json
Get /tags
Accept: application/json
Content-Type: application/json
Post /users
Accept: application/json
Content-Type: application/json
{
"username": "john",
"email": "john@gmail.com",
"password": "$3cR3tP@$$w0rD"
}
Post /users/login
Accept: application/json
Content-Type: application/json
{
"email": "john@gmail.com",
"password": "$3cR3tP@$$w0rD"
}
Get /users
Accept: application/json
Content-Type: application/json
Put /users
Accept: application/json
Content-Type: application/json
{
"user": {
"email": "john@gmail.com",
"username": "john",
"password": "n3Wp@$$w0rD",
"image": "https://mediumclone.s3.us-west-2.amazonaws.com/john.png",
"bio": "tl;dr good boy)"
}
}
Nest is an MIT-licensed open source project. It can grow thanks to the sponsors and support by the amazing backers. If you'd like to join them, please read more here.
- Author - Kamil Myśliwiec
- Website - https://nestjs.com
- Twitter - @nestframework
Nest is MIT licensed.