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

https://github.com/yeukfei02/multivendor-api

multivendor-api
https://github.com/yeukfei02/multivendor-api

apollo-server aws-lambda graphql hacktoberfest nexus nodejs postgres prisma serverless typescript

Last synced: 7 months ago
JSON representation

multivendor-api

Awesome Lists containing this project

README

          

# multivendor-api

multivendor-api

documentation:

api url dev:

api url prod:

## Requirement

- install yarn
- install node (v14+)
- install serverless

## Testing and run

```zsh
// test api in local
$ yarn run dev

// deploy to serverless
$ yarn run deploy

// open serverless dashboard
$ yarn run dashboard

// lint code
$ yarn run lint

// format code
$ yarn run format

// run test case
$ yarn run test

// remove serverless services in aws (api gateway, lambda, s3, cloudformation)
$ yarn run remove

// generate schema.graphql
$ yarn run generate:nexus

// generate schema.prisma and prisma client
$ yarn run prisma:generate

// create migration file if schema.prisma changed
$ yarn run prisma:migrate:dev

// reset database
$ yarn run prisma:migrate:reset

// apply pending migrations in the production/staging database
$ yarn run prisma:migrate:deploy

// check migrations status in the production/staging database
$ yarn run prisma:migrate:status

// push schema.prisma state to database
$ yarn run prisma:db:push

// seed data to database
$ yarn run prisma:db:seed

// validate schema.prisma
$ yarn run prisma:validate

// format schema.prisma
$ yarn run prisma:format

// open prisma studio
$ yarn run prisma:studio
```