http://miniwp.irsantyohadi.com/
baseUrl = http:localhost:3000/
Routes | Method | Request Body | Response Data | Response Error | Description |
---|---|---|---|---|---|
/users/signup |
POST | { firstname , lastname , username, email, password } |
{ access_token } |
400 ({email} has been registered!) 400 ( {email} is not a valid email!) ( ${username} has been registered!) |
Register a new user |
/users/signin |
POST | { username, password } |
{ access_token } |
400 (Wrong email/password) | Log in and get an email verification! |
/users/googleSignIn |
POST | { id_token } |
{ access_token } |
Sign in with Google and get a new password! |
| Routes | Method | Request Body | Response Success | Response Error|Description |
|------------------------|--------|-----------------------------------|----------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------|
| /articles/all
| GET | - | { data }
| 500 (Internal Server Error)| |
| /articles/
| POST | {title,content,userId,imageUrl}
| ${success message}
| 401(Invalid Token)
401(Please Login)
404 (Wrong User)|Create a new Article! |
| /articles/:articleId
| DELETE | - | { deleted }
| 401 (Invalid Token)
401 (Please Login)
401 (Unauthorized)
404 (Wrong User)
500 (Internal Server Error)|Delete an Article |
| /articles/
| GET | | | 401 (Invalid Token)
401 (Please Login)
404 (Wrong User)
500 (Internal Server Error)|for searchin articles and take article for spesific user |
| /articles/:id
| PUT | - | { updated }
| 401 (Invalid Token)
401 (Please login )
401 Unauthorized
404 (Wrong User)
500 (Internal Server Error)|Updated an article! |