Documente Academic
Documente Profesional
Documente Cultură
Table Mysql
A. Get API
API Name : {url_domain}/customer/getlist
Method : GET
Header : Bearer(spasi){JWTTOKEN}
FORMAT :
customerId : xxxx,
customerName : xxxx,
createdBy : xxxx,
createdDate: xxxx (Format Date “dd MMM yyyy”),
modifiedBy: xxxx (JIKA NULL, kasih string “-”),
modifiedDate: xxxx
} (JIKA NULL, kasih string “-”, Format Date “dd MMM
], yyyy”)
Status: 200,
Message: Success
}
IF NOT AUTHENTICATED JWT
{ Validasi yang dicek setelah JWT decode adalah
Rows: [], Cek userID dan email ke database,
Status: 500,
Message: Not
Authenticated
}
IF ERROR TRY CATCH
{
Rows: [],
Status: 404,
Message: {Message Error
Java Exception}
}
B. Post API Insert
API Name : {url_domain}/customer/insert
Method : POST
Header : Bearer(spasi){JWTTOKEN}
FORMAT :
Return JSON
{
Status : 200,
Message: Successfully Insert
}
Return JSON
{
status:500,
message: Not Authenticated
}
Return JSON
{
status:404,
message: {Message Error Java Exception}
}
C. Post API Update
API Name : {url_domain}/customer/update
Method : POST
Header : Bearer(spasi){JWTTOKEN}
FORMAT :
Return JSON
{
Status : 200,
Message: Successfully Updated
}
Return JSON
{
status:500,
message: Not Authenticated
}
Return JSON
{
status:404,
message: {Message Error Java Exception}
}
D. Delete API
API Name : {url_domain}/customer/delete
Method : DELETE
Header : Bearer(spasi){JWTTOKEN}
FORMAT :
Return JSON
{
Status : 200,
Message: Successfully Deleted
}
Return JSON
{
status:404,
message: {Message Error Java Exception}
}