Field Name | Type | Description |
---|---|---|
_id | ObjectId | Article ID is auto generate by MongoDB when admin add article |
title | string | The article title |
img | string | Image of an article |
desc | string | Short description about the article |
content | string | Main content of the article |
author | string | Admin name who post the article |
likes | array | List of the user_id who likes the article |
createdAt | date | Article created date is auto generated by MongoDB when user add data |
updatedAt | date | Article updated date is auto generated by MongoDB when user update data |
This route is connected to Article collection of MongoDB. Only user with admin role can add the article.
Request :
- Method : POST
- Endpoint :
/article
- Header :
- Content-Type: application/json
- Accept: application/json
- Body :
{
"title": "string",
"img": "string",
"desc": "string",
"content": "string",
"author": "string"
}
Response :
{
"message": "Article added successfully",
"data": {
"_id": "ObjectId",
"title": "string",
"img": "string",
"desc": "string",
"content": "string",
"author": "string",
"likes": "array",
"createdAt": "Date",
"updatedAt": "Date"
}
}
This route is connected to Article collection of MongoDB. User with admin and member role can read the article.
Request :
- Method : GET
- Endpoint :
/article
- Header :
- Accept: application/json
Response :
{
"_id": "ObjectId",
"title": "string",
"img": "string",
"desc": "string",
"content": "string",
"author": "string",
"likes": "array",
"createdAt": "Date",
"updatedAt": "Date"
}
This route is connected to Article collection of MongoDB. User with admin and member role can read the article by id.
Request :
- Method : GET
- Endpoint :
/article/:id
- Header :
- Accept: application/json
Response :
{
"_id": "ObjectId",
"title": "string",
"img": "string",
"desc": "string",
"content": "string",
"author": "string",
"likes": "array",
"createdAt": "Date",
"updatedAt": "Date"
}
This route is connected to Article collection of MongoDB. Only user with admin role can update the article by id.
Request :
- Method : PATCH
- Endpoint :
/article/:id
- Header :
- Content-Type: application/json
- Accept: application/json
- Body :
{
"title": "string",
"img": "string",
"desc": "string",
"content": "string",
"author": "string"
}
Response :
{
"message": "Article updated successfully",
"data": {
"_id": "ObjectId",
"title": "string",
"img": "string",
"desc": "string",
"content": "string",
"author": "string",
"likes": "array",
"createdAt": "Date",
"updatedAt": "Date"
}
}
This route is connected to Article collection of MongoDB. Only with admin role can delete the article by id.
Request :
- Method : DELETE
- Endpoint :
/article/:id
- Header :
- Accept: application/json
Response :
{
"message": "Article deleted"
}
Field Name | Type | Description |
---|---|---|
_id | int | Psychologist ID is auto generate by MongoDB when admin add Psychologist profile |
name | string | Name of the psychologist |
img | string | Photo profile of the psychologist |
profile | string | The introduction about psychologist background and experience |
expertise | array | List of psychologist expertise area |
rating | double | User rating of the psychologist |
createdAt | date | Psychologist created date is auto generated by MongoDB when user add data |
updatedAt | date | Psychologist updated date is auto generated by MongoDB when user update |
This route is connected to Psychologist Profile collection of MongoDB. Only user with admin role can add the psychologist profile.
Request :
- Method : POST
- Endpoint :
/psikolog
- Header :
- Content-Type: application/json
- Accept: application/json
- Body :
{
"name": "string",
"img": "string",
"expert role": "string",
"profile": "string",
"expertise": "string",
"rating": "double"
}
Response :
{
"message": "Psychologist profile updated successfully",
"data": {
"_id": "ObjectId",
"name": "string",
"img": "string",
"profile": "string",
"expertise": "string",
"rating": "double",
"createdAt": "Date",
"updatedAt": "Date"
}
}
This route is connected to Psychologist Profile collection of MongoDB. User with admin and member role can read the psychologist profile.
Request :
- Method : GET
- Endpoint :
/psikolog
- Header :
- Accept: application/json
Response :
{
"_id": "ObjectId",
"name": "string",
"img": "string",
"profile": "string",
"expertise": "string",
"rating": "double",
"createdAt": "Date",
"updatedAt": "Date"
}
This route is connected to Psychologist Profile collection of MongoDB. User with admin and member role can read the psychologist profile by id.
Request :
- Method : GET
- Endpoint :
/psikolog/:id
- Header :
- Accept: application/json
Response :
{
"_id": "ObjectId",
"name": "string",
"img": "string",
"profile": "string",
"expertise": "string",
"rating": "double",
"createdAt": "Date",
"updatedAt": "Date"
}
This route is connected to Psychologist Profile collection of MongoDB. User with admin role can update the psychologist profile by id.
Request :
- Method : PATCH
- Endpoint :
/psikolog/:id
- Header :
- Content-Type: application/json
- Accept: application/json
- Body :
{
"name": "string",
"img": "string",
"expert role": "string",
"profile": "string",
"expertise": "string",
"rating": "double"
}
Response :
{
"message": "Psychologist profile updated successfully",
"data": {
"_id": "ObjectId",
"name": "string",
"img": "string",
"profile": "string",
"expertise": "string",
"rating": "double",
"createdAt": "Date",
"updatedAt": "Date"
}
}
This route is connected to Psychologist Profile collection of MongoDB. User with admin and member role can read the psychologist profile by id.
Request :
- Method : DELETE
- Endpoint :
/psikolog/:id
- Header :
- Content-Type: application/json
- Accept: application/json
Response :
{
"message": "Psychologist profile deleted"
}
Field Name | Type | Description |
---|---|---|
_id | int | User ID is auto generate by MongoDB when admin add profile |
name | string | User full name |
string | User email | |
password | string | User password |
role | string | User role either member or admin |
createdAt | date | User created date is auto generated by MongoDB when user register |
updatedAt | date | User updated date is auto generated by MongoDB when user update |
This route is connected to Users Profile collection of MongoDB. User will create this profile when he registering via register page
Request :
- Method : POST
- Endpoint :
/user
- Header :
- Content-Type: application/json
- Accept: application/json
- Body :
{
"name": "string",
"email": "string",
"password": "string",
"role": "string"
}
Response :
{
"message": "User created successfully",
"data": {
"id": "ObjectId",
"name": "string",
"email": "string",
"password": "string",
"role": "string",
"createdAt": "Date",
"updatedAt": "Date"
}
}
This route is connected to Users Profile collection of MongoDB. Only admin role can access the information of all user
Request :
- Method : GET
- Endpoint :
/user
- Header :
- Accept: application/json
Response :
{
"id": "ObjectId",
"name": "string",
"email": "string",
"role": "string",
"createdAt": "Date",
"updatedAt": "Date"
}
This route is connected to Users Profile collection of MongoDB. User who registered can see his information by visiting user page
Request :
- Method : GET
- Endpoint :
/user/:id
- Header :
- Accept: application/json
Response :
{
"id": "ObjectId",
"name": "string",
"email": "string",
"password": "string",
"role": "string",
"createdAt": "Date",
"updatedAt": "Date"
}
This route is connected to Users Profile collection of MongoDB. User who registered can update his profile through visiting user page and click on edit profile
Request :
- Method : PATCH
- Endpoint :
/user/id
- Header :
- Content-Type: application/json
- Accept: application/json
- Body :
{
"name": "string",
"password": "string"
}
Response :
{
"message": "User profile updated successfully"
}
This route is connected to Users Profile collection of MongoDB. Admin and member role can deleted the user profile
Request :
- Method : DELETE
- Endpoint :
/user
- Header :
- Accept: application/json
Response :
{
"message": "User deleted"
}
Field Name | Type | Description |
---|---|---|
_id | int | Webinar ID is auto generate by MongoDB when admin add profile |
title | string | Webinar title |
thumbnail | string | Webinar image thumbnail |
desc | string | Description about webinar topic |
url | string | Url of webinar video |
likes | array | List of the user_id who likes the webinar |
createdAt | date | Webinar created date is auto generated by MongoDB when user register |
updatedAt | date | Webinar updated date is auto generated by MongoDB when user update |
This route is connected to Webinar collection of MongoDB. Only admin role can add webinar video via dashboard
Request :
- Method : POST
- Endpoint :
/webinars
- Header :
- Content-Type: application/json
- Accept: application/json
- Body :
{
"title": "string",
"thumbnail": "string",
"desc": "string",
"url": "string"
}
Response :
{
"message": "Webinar added successfully",
"data": {
"_id": "ObjectId",
"title": "string",
"thumbnail": "string",
"desc": "string",
"url": "string",
"create_date": "date",
"likes": "array",
"createdAt": "Date",
"updatedAt": "Date"
}
}
This route is connected to Webinar collection of MongoDB. Admin and member role can view the webinar video by visiting webinar page
Request :
- Method : GET
- Endpoint :
/webinars
- Header :
- Accept: application/json
Response :
{
"_id": "ObjectId",
"title": "string",
"thumbnail": "string",
"desc": "string",
"url": "string",
"create_date": "date",
"likes": "array",
"createdAt": "Date",
"updatedAt": "Date"
}
This route is connected to Webinar collection of MongoDB. Admin and member role can view the webinar video by visiting webinar page
Request :
- Method : GET
- Endpoint :
/webinars/:id
- Header :
- Accept: application/json
Response :
{
"_id": "ObjectId",
"title": "string",
"thumbnail": "string",
"desc": "string",
"url": "string",
"create_date": "date",
"likes": "array",
"createdAt": "Date",
"updatedAt": "Date"
}
This route is connected to Webinar collection of MongoDB. Only admin role can update the webinar video via dashboard
Request :
- Method : PATCH
- Endpoint :
/webinars/:id
- Header :
- Content-Type: application/json
- Accept: application/json
- Body :
{
"name": "string",
"email": "string",
"password": "string",
"role": "string",
"create_date": "date"
}
Response :
{
"message": "Webinar updated successfully",
"data": {
"_id": "ObjectId",
"title": "string",
"thumbnail": "string",
"desc": "string",
"url": "string",
"create_date": "date",
"likes": "array",
"createdAt": "Date",
"updatedAt": "Date"
}
}
This route is connected to Webinar collection of MongoDB. Only admin role can delete the webinar video via dashboard
Request :
- Method : DELETE
- Endpoint :
/webinars/:id
- Header :
- Accept: application/json
Response :
{
"message": "Webinar deleted"
}
This route is connected to Register of MongoDB. Only member role can join the website
- Endpoint :
/register
Request :
{
"name": "string",
"email": "string",
"password": "string"
}
Response :
{
"message": "user created"
}
This route is connected to Login of MongoDB. Only member role can join the website
- Endpoint :
/login
Request :
{
"email": "string",
"password": "string"
}
Response :
{
"accessToken": "string"
}
Field Name | Type | Description |
---|---|---|
_id | int | Coaching ID is auto generate by MongoDB when admin add profile |
materials | string | coaching materials |
content | string | Main content about coaching topic |
coach | string | coach who attending coaching |
categories | string | category about coaching topic |
This route is connected to coaching collection of MongoDB. Only admin role can add coaching video via dashboard
Request :
- Method : POST
- Endpoint :
/coaching
- Header :
- Content-Type: application/json
- Accept: application/json
- Body :
{
"materials": "string",
"content": "string",
"coach": "string",
"categories": "array"
}
Response :
{
"message": "coaching added successfully",
"data": {
"_id": "ObjectId",
"materials": "string",
"content": "string",
"coach": "string",
"categories": "array",
"create_date": "date",
"createdAt": "Date",
"updatedAt": "Date"
}
}
This route is connected to coaching collection of MongoDB. Admin and member role can view the coaching video by visiting coaching page
Request :
- Method : GET
- Endpoint :
/coaching
- Header :
- Accept: application/json
Response :
{
"_id": "ObjectId",
"materials": "string",
"content": "string",
"coach": "string",
"categories": "array",
"create_date": "date",
"createdAt": "Date",
"updatedAt": "Date"
}
This route is connected to coaching collection of MongoDB. Admin and member role can view the coaching video by visiting coaching page
Request :
- Method : GET
- Endpoint :
/coaching/:id
- Header :
- Accept: application/json
Response :
{{
"_id": "ObjectId",
"materials": "string",
"content": "string",
"coach": "string",
"categories": "array",
"create_date": "date",
"createdAt": "Date",
"updatedAt": "Date"
}
This route is connected to coaching collection of MongoDB. Only admin role can update the coaching via dashboard
Request :
- Method : PATCH
- Endpoint :
/coaching/:id
- Header :
- Content-Type: application/json
- Accept: application/json
- Body :
{
"materials": "string",
"content": "string",
"coach": "string",
"categories": "array"
}
Response :
{
"message": "coaching updated successfully",
"data": {
{
"_id": "ObjectId",
"materials": "string",
"content": "string",
"coach": "string",
"categories": "array",
"create_date": "date",
"createdAt": "Date",
"updatedAt": "Date"
}
}
}
This route is connected to coaching collection of MongoDB. Only admin role can delete the coaching via dashboard
Request :
- Method : DELETE
- Endpoint :
/coaching/:id
- Header :
- Accept: application/json
Response :
{
"message": "coaching deleted"
}
Field Name | Type | Description |
---|---|---|
_id | int | dyslexia ID is auto generate by MongoDB when admin add profile |
name | string | dyslexia's name |
price | integer | dyslexia's price packet |
benefit | string | benefit of dyslexia |
This route is connected to dyslexia collection of MongoDB. Only admin role can add dyslexia video via dashboard
Request :
- Method : POST
- Endpoint :
/dyslexia
- Header :
- Content-Type: application/json
- Accept: application/json
- Body :
{
"name": "string",
"price": "integer",
"benefit": "string"
}
Response :
{
"message": "dyslexia added successfully",
"data": {
"_id": "ObjectId",
"name": "string",
"price": "integer",
"benefit": "string",
"createdAt": "Date",
"updatedAt": "Date"
}
}
This route is connected to dyslexia collection of MongoDB. Admin and member role can view the dyslexia video by visiting dyslexia page
Request :
- Method : GET
- Endpoint :
/dyslexia
- Header :
- Accept: application/json
Response :
{
"_id": "ObjectId",
"_id": "ObjectId",
"name": "string",
"price": "integer",
"benefit": "string",
"createdAt": "Date",
"updatedAt": "Date"
}
This route is connected to dyslexia collection of MongoDB. Admin and member role can view the dyslexia video by visiting dyslexia page
Request :
- Method : GET
- Endpoint :
/dyslexia/:id
- Header :
- Accept: application/json
Response :
{{
"_id": "ObjectId",
"name": "string",
"price": "integer",
"benefit": "string",
"createdAt": "Date",
"updatedAt": "Date"
}
This route is connected to dyslexia collection of MongoDB. Only admin role can update the dyslexia via dashboard
Request :
- Method : PATCH
- Endpoint :
/dyslexia/:id
- Header :
- Content-Type: application/json
- Accept: application/json
- Body :
{
"name": "string",
"price": "integer",
"benefit": "string"
}
Response :
{
"message": "dyslexia updated successfully",
"data": {
{
"_id": "ObjectId",
"name": "string",
"price": "integer",
"benefit": "string",
"createdAt": "Date",
"updatedAt": "Date"
}
}
}
This route is connected to dyslexia collection of MongoDB. Only admin role can delete the dyslexia via dashboard
Request :
- Method : DELETE
- Endpoint :
/dyslexia/:id
- Header :
- Accept: application/json
Response :
{
"message": "dyslexia deleted"
}
Field Name | Type | Description |
---|---|---|
_id | int | Health-test ID is auto generate by MongoDB when admin add profile |
question | string | Health-test's question |
answer | array | Health-test's answer |
This route is connected to health-test collection of MongoDB. Only admin role can add health-test via dashboard
Request :
- Method : POST
- Endpoint :
/health-test
- Header :
- Content-Type: application/json
- Accept: application/json
- Body :
{
"question": "string",
"answer": "array"
}
Response :
{
"message": "Health-test added successfully",
"data": {
"_id": "ObjectId",
"question": "string",
"answer": "array",
"createdAt": "Date",
"updatedAt": "Date"
}
}
This route is connected to health-test collection of MongoDB. Admin and member role can view the health-test by visiting health-test page
Request :
- Method : GET
- Endpoint :
/health-test
- Header :
- Accept: application/json
Response :
{
"_id": "ObjectId",
"question": "string",
"answer": "array",
"createdAt": "Date",
"updatedAt": "Date"
}
This route is connected to health-test collection of MongoDB. Admin and member role can view the health-test video by visiting health-test page
Request :
- Method : GET
- Endpoint :
/health-test/:id
- Header :
- Accept: application/json
Response :
{{
"_id": "ObjectId",
"question": "string",
"answer": "array",
"createdAt": "Date",
"updatedAt": "Date"
}
This route is connected to health-test collection of MongoDB. Only admin role can update the health-test via dashboard
Request :
- Method : PATCH
- Endpoint :
/health-test/:id
- Header :
- Content-Type: application/json
- Accept: application/json
- Body :
{
"question": "string",
"answer": "array"
}
Response :
{
"message": "Health-test updated successfully",
"data": {
{
"_id": "ObjectId",
"question": "string",
"answer": "array",
"createdAt": "Date",
"updatedAt": "Date"
}
}
}
This route is connected to health-test collection of MongoDB. Only admin role can delete the health-test via dashboard
Request :
- Method : DELETE
- Endpoint :
/health-test/:id
- Header :
- Accept: application/json
Response :
{
"message": "Health-test deleted"
}
Field Name | Type | Description |
---|---|---|
_id | int | Screening ID is auto generate by MongoDB when admin add profile |
question | string | Screening's question |
answer | array | Screening's answer |
This route is connected to screening collection of MongoDB. Only admin role can add screening via dashboard
Request :
- Method : POST
- Endpoint :
/screening
- Header :
- Content-Type: application/json
- Accept: application/json
- Body :
{
"question": "string",
"answer": "array"
}
Response :
{
"message": "Screening added successfully",
"data": {
"_id": "ObjectId",
"question": "string",
"answer": "array",
"createdAt": "Date",
"updatedAt": "Date"
}
}
This route is connected to screening collection of MongoDB. Admin and member role can view the screening by visiting screening page
Request :
- Method : GET
- Endpoint :
/screening
- Header :
- Accept: application/json
Response :
{
"_id": "ObjectId",
"question": "string",
"answer": "array",
"createdAt": "Date",
"updatedAt": "Date"
}
This route is connected to screening collection of MongoDB. Admin and member role can view the screening video by visiting screening page
Request :
- Method : GET
- Endpoint :
/screening/:id
- Header :
- Accept: application/json
Response :
{{
"_id": "ObjectId",
"question": "string",
"answer": "array",
"createdAt": "Date",
"updatedAt": "Date"
}
This route is connected to screening collection of MongoDB. Only admin role can update the screening via dashboard
Request :
- Method : PATCH
- Endpoint :
/screening/:id
- Header :
- Content-Type: application/json
- Accept: application/json
- Body :
{
"question": "string",
"answer": "array"
}
Response :
{
"message": "screening updated successfully",
"data": {
{
"_id": "ObjectId",
"question": "string",
"answer": "array",
"createdAt": "Date",
"updatedAt": "Date"
}
}
}
This route is connected to screening collection of MongoDB. Only admin role can delete the screening via dashboard
Request :
- Method : DELETE
- Endpoint :
/screening/:id
- Header :
- Accept: application/json
Response :
{
"message": "screening deleted"
}
Field Name | Type | Description |
---|---|---|
_id | int | paket ID is auto generate by MongoDB when admin add profile |
name | string | paket's name |
price | integer | paket's price packet |
benefit | string | benefit of paket |
This route is connected to paket collection of MongoDB. Only admin role can add paket video via dashboard
Request :
- Method : POST
- Endpoint :
/paket
- Header :
- Content-Type: application/json
- Accept: application/json
- Body :
{
"name": "string",
"price": "integer",
"benefit": "string"
}
Response :
{
"message": "paket added successfully",
"data": {
"_id": "ObjectId",
"name": "string",
"price": "integer",
"benefit": "string",
"createdAt": "Date",
"updatedAt": "Date"
}
}
This route is connected to paket collection of MongoDB. Admin and member role can view the paket video by visiting paket page
Request :
- Method : GET
- Endpoint :
/paket
- Header :
- Accept: application/json
Response :
{
"_id": "ObjectId",
"_id": "ObjectId",
"name": "string",
"price": "integer",
"benefit": "string",
"createdAt": "Date",
"updatedAt": "Date"
}
This route is connected to paket collection of MongoDB. Admin and member role can view the paket video by visiting paket page
Request :
- Method : GET
- Endpoint :
/paket/:id
- Header :
- Accept: application/json
Response :
{{
"_id": "ObjectId",
"name": "string",
"price": "integer",
"benefit": "string",
"createdAt": "Date",
"updatedAt": "Date"
}
This route is connected to paket collection of MongoDB. Only admin role can update the paket via dashboard
Request :
- Method : PATCH
- Endpoint :
/paket/:id
- Header :
- Content-Type: application/json
- Accept: application/json
- Body :
{
"name": "string",
"price": "integer",
"benefit": "string"
}
Response :
{
"message": "paket updated successfully",
"data": {
{
"_id": "ObjectId",
"name": "string",
"price": "integer",
"benefit": "string",
"createdAt": "Date",
"updatedAt": "Date"
}
}
}
This route is connected to paket collection of MongoDB. Only admin role can delete the paket via dashboard
Request :
- Method : DELETE
- Endpoint :
/paket/:id
- Header :
- Accept: application/json
Response :
{
"message": "paket deleted"
}
Field Name | Type | Description |
---|---|---|
_id | int | consultation ID is auto generate by MongoDB when admin add profile |
user | string | user's name |
psikolog | string | psikolog's name |
consultation_schedule | date | schedule of consultation |
consultation_paket | string | paket of consultation |
This route is connected to consultation collection of MongoDB. Only admin role can add consultation video via dashboard
Request :
- Method : POST
- Endpoint :
/consultation
- Header :
- Content-Type: application/json
- Accept: application/json
- Body :
{
"user": "string",
"psikolog": "string",
"consultation_schedule": "date",
"consultation_paket": "string"
}
Response :
{
"message": "consultation added successfully",
"data": {
"_id": "ObjectId",
"user": "string",
"psikolog": "string",
"consultation_schedule": "date",
"consultation_paket": "string",
"createdAt": "Date",
"updatedAt": "Date"
}
}
This route is connected to consultation collection of MongoDB. Admin and member role can view the consultation video by visiting consultation page
Request :
- Method : GET
- Endpoint :
/consultation
- Header :
- Accept: application/json
Response :
{
"_id": "ObjectId",
"user": "string",
"psikolog": "string",
"consultation_schedule": "date",
"consultation_paket": "string",
"createdAt": "Date",
"updatedAt": "Date"
}
This route is connected to consultation collection of MongoDB. Admin and member role can view the consultation video by visiting consultation page
Request :
- Method : GET
- Endpoint :
/consultation/:id
- Header :
- Accept: application/json
Response :
{{
"_id": "ObjectId",
"user": "string",
"psikolog": "string",
"consultation_schedule": "date",
"consultation_paket": "string",
"createdAt": "Date",
"updatedAt": "Date"
}
This route is connected to consultation collection of MongoDB. Only admin role can update the consultation via dashboard
Request :
- Method : PATCH
- Endpoint :
/consultation/:id
- Header :
- Content-Type: application/json
- Accept: application/json
- Body :
{
"user": "string",
"psikolog": "string",
"consultation_schedule": "date",
"consultation_paket": "string"
}
Response :
{
"message": "consultation updated successfully",
"data": {
{
"_id": "ObjectId",
"user": "string",
"psikolog": "string",
"consultation_schedule": "date",
"consultation_paket": "string",
"createdAt": "Date",
"updatedAt": "Date"
}
}
}
This route is connected to consultation collection of MongoDB. Only admin role can delete the consultation via dashboard
Request :
- Method : DELETE
- Endpoint :
/consultation/:id
- Header :
- Accept: application/json
Response :
{
"message": "consultation deleted"
}