Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,18 +1,19 @@
### POST /logout
POST http://localhost:3000/api/auth/logout
Content-Type: application/json

{"refreshToken": "244246b8-4024-4044-bd71-6fa00731ad6f"}

###
### POST /refresh
POST http://localhost:3000/api/auth/refresh
Content-Type: application/json

{"refreshToken": "244246b8-4024-4044-bd71-6fa00731ad6f"}

###
### POST /login
POST http://localhost:3000/api/auth/login
Content-Type: application/json

{"email": "wonho@workly.page", "password": "test1234"}

###
> {% client.global.set("accessToken", response.body.accessToken); %}
23 changes: 23 additions & 0 deletions packages/api/server/controllers/http/team.http
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
### GET /{id}/members
GET http://localhost:3000/api/teams/1/members
Accept: application/json
Authorization: Bearer {{accessToken}}

### POST /{id}/join
POST http://localhost:3000/api/teams/2/join
Content-Type: application/json
Authorization: Bearer {{accessToken}}

{"userId": 2, "teamId": 1}

### GET /{name}
GET http://localhost:3000/api/teams/Appetis
Accept: application/json
Authorization: Bearer {{accessToken}}

### POST /
POST http://localhost:3000/api/teams
Content-Type: application/json
Authorization: Bearer {{accessToken}}

{"name": "Appetis", "userId": 1}
93 changes: 93 additions & 0 deletions packages/api/server/controllers/http/user.http
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
### POST /{id}/avatar
POST http://localhost:3000/api/users/1/avatar
Content-Type: multipart/form-data; boundary=WebAppBoundary
Authorization: Bearer {{accessToken}}
#Authorization: Bareer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6MSwiaWF0IjoxNjM2NDMzMDEzLCJleHAiOjE2MzY0MzQ4MTMsImlzcyI6IndvcmtseSJ9.TNpDA_0h4eRVcWkSWf_yxQ0L1jnVJaXdvRFmPKTduNM

--WebAppBoundary
Content-Disposition: form-data; name="avatar"; filename="avatar.png"

< /Users/wonho/Downloads/avatar.png
--WebAppBoundary--

### POST /{id}/profile
POST http://localhost:3000/api/users/1/profile
Content-Type: application/json
Authorization: Bearer {{accessToken}}

{
"name": "Wonho Lee",
"department": "IT",
"position": "Developer",
"phone": "111-333-2222",
"phone_ext": "333",
"status": "OF"
}

### POST /{id}/verify
POST http://localhost:3000/api/users/2/verify
Content-Type: application/json

{"code": "278645"}

### POST /
POST http://localhost:3000/api/users
Content-Type: application/json

{"email": "test1@test.com", "password": "test1234"}

### GET /
GET http://localhost:3000/api/users
Accept: application/json
Authorization: Bareer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6MSwiaWF0IjoxNjM2NDMzMDEzLCJleHAiOjE2MzY0MzQ4MTMsImlzcyI6IndvcmtseSJ9.TNpDA_0h4eRVcWkSWf_yxQ0L1jnVJaXdvRFmPKTduNM

### GET /{id}
GET http://localhost:3000/api/users/1
Accept: application/json
Authorization: Bareer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6MSwiaWF0IjoxNjM2NDMzMDEzLCJleHAiOjE2MzY0MzQ4MTMsImlzcyI6IndvcmtseSJ9.TNpDA_0h4eRVcWkSWf_yxQ0L1jnVJaXdvRFmPKTduNM

### POST /{id}/name
POST http://localhost:3000/api/users/1/name
Content-Type: application/json
Authorization: Bearer {{accessToken}}

{
"name": "Wono"
}

### POST /{id}/department
POST http://localhost:3000/api/users/1/department
Content-Type: application/json
Authorization: Bearer {{accessToken}}

{
"department": "IT1"
}

### POST /{id}/position
POST http://localhost:3000/api/users/1/position
Content-Type: application/json
Authorization: Bearer {{accessToken}}

{
"position": "Developer1"
}

### POST /{id}/phone
POST http://localhost:3000/api/users/1/phone
Content-Type: application/json
Authorization: Bearer {{accessToken}}

{
"phone": "999-999-9999"
}

### POST /{id}/phone-ext
POST http://localhost:3000/api/users/1/phone-ext
Content-Type: application/json
Authorization: Bearer {{accessToken}}

{
"phoneExt": "999"
}

24 changes: 0 additions & 24 deletions packages/api/server/controllers/team.http

This file was deleted.

53 changes: 0 additions & 53 deletions packages/api/server/controllers/user.http

This file was deleted.

Loading