An open API service indexing awesome lists of open source software.

https://github.com/mkloz/swapi

Nestjs backend(starwars api)
https://github.com/mkloz/swapi

api backend nestjs rest typescript

Last synced: about 2 months ago
JSON representation

Nestjs backend(starwars api)

Awesome Lists containing this project

README

          


Nest Logo

Starwars API like Swapi on NestJS

## Description

API where saved all information about starwars.

## Installation

```bash
$ npm install
```

## Running the app

Set all environment variable(.env file in the root of project) and constants. Then run the application

```bash
# Building
$ npm run build
# Up migrations
$ npm run migration:run
# Seeding
$ npm run seed:run
# After that you can start
$ npm run start
```

Start with docker compose
Set all variables in .env file(instead DB_HOST=localhost you should use DB_HOST=mysql)

```bash
# Building images
$ docker-compose build
# Start app
$ docker-compose up

```

If you want to check out a state of program -> /api/health (only for admins)

## Documentation

Swagger is used here. Api documentation is located on route `/api/docs`