intersvyaz
v1.0.2
Published
Intercom control from intersvyaz
Downloads
2
Maintainers
Readme
Intercom control from intersvyaz
Install
npm install intersvyaz
Usage
import Intersvyaz from 'intersvyaz';
const client = new Intersvyaz({ username, password });
API
Get network status
await client.getStatus();
Get user information
await client.getUser();
Get user address
await client.getAddress();
Get current balance
await client.getBalance();
Get list of intercoms
await client.getDomofon();
await client.getDomofon(relayId);
Open intercom
await client.openDomofon(relayId);
Get list of intercom cameras
await client.getCams(entranceUid);
Get history
await client.getHistory();
await client.getHistory({
from: '2024-08-01',
to: '2024-08-08',
page: 1,
perPage: 5
});
Get list IPTV
await client.getIPTV();
await client.getIPTV({
channelId: 1640,
topicId: '6,17,20,12,16'
}, 'text');
SIP
await client.start();
client.stop();
Events
Authorization
client.on('auth', ({ username, password, sip, accessToken, lkToken, atExpiredTime, ltExpiredTime }) => {});
SIP
client.on('sip:register', ({ res, req, error, ok }) => {});
client.on('sip:invite', ({ req }) => {});