Path Params
| Name | Type | Required | Description | Default |
|---|
Query Params
| Name | Type | Required | Description | Default |
|---|---|---|---|---|
keyword | string | Optional | Keyword | - |
offset | number | Optional | offset | - |
paged | boolean | Optional | paged | - |
pageNumber | number | Optional | Trang hiện tại | - |
pageSize | number | Optional | Số lượng mỗi trang | - |
sort.sorted | boolean | Optional | sort.sorted | - |
sort.unsorted | boolean | Optional | sort.unsorted | - |
status | number | Optional | status | - |
unpaged | boolean | Optional | unpaged | - |
Headers
| Header | Required | Description | Example |
|---|---|---|---|
Authorization | Required | Bearer token xác thực | Bearer <token> |
Response
200Thành công
| Trường | Kiểu | Mô tả |
|---|---|---|
| data | object | Dữ liệu trả về |
| data.content | array | Danh sách chatbot |
| data.content[].bot | object | Thông tin bot |
| data.content[].bot.botId | string | ID của bot |
| data.content[].bot.botName | string | Tên bot |
| data.content[].bot.modelCode | string | Model đang sử dụng |
| data.content[].fileCount | number | Số lượng file đã tải lên |
| data.totalElements | number | Tổng số bot |
| data.totalPages | number | Tổng số trang |
| data.pageNumber | number | Trang hiện tại (bắt đầu từ 0) |
| data.pageSize | number | Số lượng phần tử mỗi trang |
| resultCode | string | Mã kết quả |
| resultMsg | string | Thông báo kết quả |
401Không xác thực
| Trường | Kiểu | Mô tả |
|---|---|---|
| error | string | Thông báo lỗi xác thực |
example.title:
{
"200": {
"data": {
"content": [
{
"bot": {
"createdAt": "2025-06-12T09:55:20.108+00:00",
"updatedAt": null,
"createdBy": "SAMPLE_USER",
"updatedBy": null,
"botId": "9e725fbf-d27a-4308-9368-6d28e9a61724",
"botName": "Rubee Bot 1",
"botDescription": "Bot của Chiến Rubee",
"isPublic": false,
"status": 1,
"coreBotId": null,
"modelCode": "gpt-4o",
"creativityLevel": null,
"writeStyleCode": null,
"responseFormatCode": null,
"answerStyleCode": null,
"enableResponseOutDataTrain": null,
"outputLanguage": null,
"quoteDocument": null,
"suggestNextQuestion": null
},
"fileCount": 0,
"botCreater": true
}
],
"pageable": {
"sort": {
"unsorted": true,
"sorted": false,
"empty": true
},
"pageSize": 20,
"pageNumber": 0,
"offset": 0,
"unpaged": false,
"paged": true
},
"last": true,
"totalElements": 2,
"totalPages": 1,
"first": true,
"numberOfElements": 2,
"sort": {
"unsorted": true,
"sorted": false,
"empty": true
},
"number": 0,
"size": 20,
"empty": false
},
"resultCode": "0",
"resultMsg": "Success"
}
}API Request
GET
https://troly.mobifone.vn/api/v1/am/bot/getAllBotsTry It Out
Test Endpoint
const axios = require('axios');
let config = {
method: 'get',
maxBodyLength: Infinity,
url: 'https://troly.mobifone.vn/api/v1/am/bot/getAllBots?keyword&offset&paged&pageNumber&pageSize&sort.sorted&status&unpaged',
headers: {
'Authorization: <YOUR_ACCESS_TOKEN_BEARER>'
}
};
axios.request(config)
.then((response) => {
console.log(JSON.stringify(response.data));
})
.catch((error) => {
console.log(error);
});