18.17.1
- expressjs 4.19.2
- typescript 5.4.5
- node-nlp 4.27.0
- db-migrate 0.11.14
- mysql2 3.10.3
To get started with the Chatbot API, clone the repository and install the required dependencies in package.json
:
git clone https://github.com/dionisius-lg/chatbot-api.git
cd chatbot-api
npm install
Rename or copy .env.example
to .env
, then setup the 'datasources' for your application.
To apply new migration
npx db-migrate up
To cancel all migration
npx db-migrate down
-
Fetch Entity Data
GET /entities
This endpoint is used to show all data -
Create New Entity Data
POST /entities
This endpoint is used to create new data -
Fetch Entity by ID
GET /entities/{id}
This endpoint is used to show data by ID -
Update Entity Data by ID
PUT /entities/{id}
This endpoint is used to update existing data by ID -
Import Entity Data
POST /entities/import
This endpoint is used to import data by uploaded file excel
-
Export Entity Data
GET /exports/entities
This endpoint is used to export data to excel -
Export FAQ Data
GET /exports/faqs
This endpoint is used to export data to excel -
Export FAQ Answers Data
GET /exports/faq_answers
This endpoint is used to export data to excel -
Export FAQ Questions Data
GET /exports/faq_questions
This endpoint is used to export data to excel -
Export Language Data
GET /exports/languages
This endpoint is used to export data to excel
-
Fetch FAQ Data
GET /faqs
This endpoint is used to show all data -
Create New FAQ Data
POST /faqs
This endpoint is used to create new data -
Fetch FAQ by ID
GET /faqs/{id}
This endpoint is used to show data by ID -
Update FAQ Data by ID
PUT /faqs/{id}
This endpoint is used to update existing data by ID -
Import FAQ Data
POST /faqs/import
This endpoint is used to import data by uploaded file excel
-
Fetch FAQ Answer Data
GET /faq_answers
This endpoint is used to show all data -
Create New FAQ Answer Data
POST /faq_answers
This endpoint is used to create new data -
Fetch FAQ Answer by ID
GET /faq_answers/{id}
This endpoint is used to show data by ID -
Update FAQ Answer Data by ID
PUT /faq_answers/{id}
This endpoint is used to update existing data by ID -
Import FAQ Answer Data
POST /faq_answers/import
This endpoint is used to import data by uploaded file excel
-
Fetch FAQ Question Data
GET /faq_questions
This endpoint is used to show all data -
Create New FAQ Question Data
POST /faq_questions
This endpoint is used to create new data -
Fetch FAQ Question by ID
GET /faq_questions/{id}
This endpoint is used to show data by ID -
Update FAQ Question Data by ID
PUT /faq_questions/{id}
This endpoint is used to update existing data by ID -
Import FAQ Question Data
POST /faq_questions/import
This endpoint is used to import data by uploaded file excel
-
Fetch Language Data
GET /languages
This endpoint is used to show all data -
Fetch Language by ID
GET /languages/{id}
This endpoint is used to show data by ID
-
Create Token
POST /token
This endpoint is used to generate new token -
Refresh Token
GET /token/refresh
This endpoint is used to regenerate old token
- Chat Message
POST /chat
This endpoint is used to post chat message
Swagger Documentation
/docs
Template import Entity Data
/public/template-entities.xlsx
Template import FAQ Data
/public/template-faq.xlsx
Template import FAQ Answer Data
/public/template-faq-answers.xlsx
Template import FAQ Question Data
/public/template-faq-questions.xlsx