![npm](https://camo.githubusercontent.com/423388f934770b422e8954394b6fac6205cf058d5f7380ae7d2084b32463c50f/68747470733a2f2f696d672e736869656c64732e696f2f6e706d2f762f7475726e2d6a732e737667)
TURN (Traversal Using Relay NAT) library written entirely in JavaScript.
- implements (most of) the features specified in RFC 5766
- supports TCP and UDP communication
- offers callback and promise based API
- can be browserified (to be used in chrome apps)
myClient = turn(serverAddr, serverPort, user, pwd, transport)
myClient.allocate(function(address) {}, function(error) {})
myClient.createPermission(address, function() {}, function(error) {})
myClient.createPermission(address)
myClient.bindChannel(address, port, channel, lifetime, function() {}, function(error) {})
myClient.bindChannelP(address, port, channel)
myClient.refresh(lifetime, function() {}, function(error) {})
myClient.refreshP(lifetime)
myClient.close(function() {}, function(error) {})
myClient.sendToRelay(bytes, address, port, function() {}, function(error))
myClient.sendToRelayP(bytes, address, port)
myClient.sendToChannel(bytes, channel, function() {}, function(error) {})
myClient.sendToChannelP(bytes, channel)
About
TURN (Traversal Using Relay NAT) library written entirely in JavaScript
MIT License
Languages
Language:JavaScript 100.0%