Skip to content

Jambonz class that handles inserting, removing, and querying the database of active sip registrations

License

Notifications You must be signed in to change notification settings

jambonz/jambonz-mw-registrar

Repository files navigation

mw-registrar CI

Jambonz class that handles inserting, removing, and querying the database of active sip registrations

const Registrar = require('jambonz-mw-registrar');
const registrar = new Registrar({host: '127.0.0.1', port: 6379});

// add a registration, optionally with an expires value in secs
registrar.add('daveh@drachtio.org', {
  contact: '10.10.1.1',
  sbcAddress: '192.168.1.1',
  protocol: 'udp'
}, 40);

const registrationDetails = await registrar.query('daveh@drachtio.org');
// {"contact":"10.10.1.1","sbcAddress":"192.168.1.1","protocol":"udp"}

// get count of users for a realm
const userCount = await registrar.getCountOfUsers('drachtio.org');

// remove a user
registrar.remove('daveh@drachtio.org');

About

Jambonz class that handles inserting, removing, and querying the database of active sip registrations

Topics

Resources

License

Stars

Watchers

Forks

Sponsor this project

 

Packages

No packages published