git clone https://github.com/typescript-tutorial/sql-rest-api.git
cd sql-rest-api
npm start
- GET: retrieve a representation of the resource
- POST: create a new resource
- PUT: update the resource
- DELETE: delete a resource
[
{
"id": "spiderman",
"username": "peter.parker",
"email": "[email protected]",
"phone": "0987654321",
"dateOfBirth": "1962-08-25T16:59:59.999Z"
},
{
"id": "wolverine",
"username": "james.howlett",
"email": "[email protected]",
"phone": "0987654321",
"dateOfBirth": "1974-11-16T16:59:59.999Z"
}
]
GET /users/wolverine
{
"id": "wolverine",
"username": "james.howlett",
"email": "[email protected]",
"phone": "0987654321",
"dateOfBirth": "1974-11-16T16:59:59.999Z"
}
{
"id": "wolverine",
"username": "james.howlett",
"email": "[email protected]",
"phone": "0987654321",
"dateOfBirth": "1974-11-16T16:59:59.999Z"
}
1
PUT /users/wolverine
{
"username": "james.howlett",
"email": "[email protected]",
"phone": "0987654321",
"dateOfBirth": "1974-11-16T16:59:59.999Z"
}
1
DELETE /users/wolverine
1