-
npm install
-
npm run seed
, to create a database indatabase.sqlite3
. -
npm start
.
A profile can be either a client
or a contractor
.
clients create contracts with contractors. contractor does jobs for clients and get paid.
Each profile has a balance property.
A contract between and client and a contractor.
Contracts have 3 statuses, new
, in_progress
, terminated
. contracts are considered active only when in status in_progress
Contracts group jobs within them.
contractor get paid for jobs by clients under a certain contract.
-
GET
/contracts/:id
-
GET
/contracts
-
GET
/jobs/unpaid
-
POST
/jobs/:job_id/pay
-
POST
/balances/deposit/:userId
-
GET
/admin/best-profession?start=<date>&end=<date>
-
GET
/admin/best-clients?start=<date>&end=<date>&limit=<integer>