Dokumentasi learning path cloud computing yang digunakan pada Capstone Project C242-PS069
- Get Articles API
- Get Details article API
- Get Banner API
- Post Register
- Post Login
- Post Reset password
- Post Edit profile
- Post Predict image
- Get Details Predict Data
Before you can use all those APIs (except login, register and reset password), you need to get an API Token for all the services we build then use it in headers authorization.
Just register and login then you get the api key😇😇
if you want to get articles
GET /api/articles
{
"status": "success",
"message": "Articles fetched successfully",
"data": [
{
"id": number,
"title": string,
"description": string,
"image": string
},
]
}
if you want to get details articles
GET /api/articles/${id}
Parameter | Type | Description |
---|---|---|
id |
number |
Required. Id of item to fetch |
{
"status": "success",
"message": "Article fetched successfully",
"data": {
"id": number,
"title": string,
"content": [
{
"section": string,
"text":string
},
...
],
"video": string
}
}
if you want to get image banner
GET /api/banners
{
"status": "success",
"message": "Banners fetched successfully",
"data": [
{
"id": number,
"image": string
},
...
]
}
if you want to register
POST /register
Parameter | Type | Description |
---|---|---|
email |
string |
Required. |
password |
string |
Required. |
username |
string |
Required. |
{
"status": "success",
"message": "User registered successfully"
}
if you want to login
POST /login
Parameter | Type | Description |
---|---|---|
email |
string |
Required. |
password |
string |
Required. |
{
"status": "success",
"message": "User logged in successfully",
data: {
"uid": string,
"name": string,
"token": string
}
}
if you forget your password you can use it
POST /reset-password
Parameter | Type | Description |
---|---|---|
email |
string |
Required. |
{
"status": "success",
"message": "Password reset email sent successfully",
}
if you want to edit your profile
POST /edit-profile
Parameter | Type | Description |
---|---|---|
newUsername |
string |
optional. |
oldPassword |
string |
optional (required if want to change password). |
newPassword |
string |
optional (required if want to change password). |
email |
string |
Required. |
{
"status": "success",
"message": "Profile updated successfully",
}
use this if you want to send image to machine learning feature
POST /predict
Parameter | Type | Description |
---|---|---|
image |
application/form-data |
required. |
{
"status": "success",
"message": "Predict fetched successfully",
"data": [
{
"id": number,
"description": string,
"image": string,
"materials": [
string,
...
],
"title": string
},
...
],
"predict": {
"confident": string,
"label": string
}
}
if you want to know about details
GET /api/recycles/${id}
Parameter | Type | Description |
---|---|---|
id |
number |
Required. Id of item to fetch |
{
"status": "success",
"message": "recycle fetched successfully",
"data": {
"id": number,
"description": string,
"makes": {
"step": [
string
...
],
"title": string
},
"title": string,
"materials": [
string
...
],
"tools": {
"materials-tools": [
string
...
],
"title": string
},
"video": string
}
}
Clone the project
git clone https://github.com/C242-PS069/cloud-computing.git
Go to the project directory
cd cloud-computing
Install dependencies
npm install
Start the server
npm run start
- Javascript Hapi js
- Tensorflow-nodejs
- Cloud Storage: to save machine learning models and fixed profile user
- Cloud Firestore: to save data user
- Firebase: to user login
- Cloud Run: to deploy backend services and machine learning prediction services
- App Engine: to deploy mobile application
- Rifqi Alisba Garwita Sutrisno as @sirWerq
- Andi Faqriyah Putra Purnama as @Andifaqriya
- Rifqi Alisba Garwita Sutrisno as @sirWerq