@3cx/api 中文文档教程
3CX Phone System API
这套 API 提供了 3CX Phone System 的接口。 仅提供有限数量的商品,但请随时与我联系以扩展列表。
可用:
- Reports
- System status
- Current user information
- Extension, Group, Fax, Phonebook contents view
Getting started
安装:
npm install @3cx/api --save
Usage
这是关于如何获取系统状态信息的示例。 请提供您的 FQDN:端口和访问凭据。
import {createClient, ConsoleClient} from '@3cx/api';
async function main(){
const http = await createClient('http://secure.3cx.my:5000', {Username: 'Admin', Password: '############'});
const api = new ConsoleClient(http);
console.log(await api.getSystemStatus());
}
main();
Samples
示例请参考 https://github.com/sherlock1982/3cx-api-samples
3CX Phone System API
This set of API provides an interface to 3CX Phone System. Only a limited amount of items is available but feel free to contact me for extending the list.
Available:
- Reports
- System status
- Current user information
- Extension, Group, Fax, Phonebook contents view
Getting started
Installation:
npm install @3cx/api --save
Usage
This is a sample on how to get system status information. Please supply your FQDN:port and access credentials.
import {createClient, ConsoleClient} from '@3cx/api';
async function main(){
const http = await createClient('http://secure.3cx.my:5000', {Username: 'Admin', Password: '############'});
const api = new ConsoleClient(http);
console.log(await api.getSystemStatus());
}
main();
Samples
For samples please refer to https://github.com/sherlock1982/3cx-api-samples