0.5.4 • Published 7 years ago

turn-js v0.5.4

Weekly downloads
16
License
MIT
Repository
github
Last release
7 years ago

CircleCI npm

Turn-JS

TURN (Traversal Using Relay NAT) library written entirely in JavaScript.

Features

  • 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)

Install

npm install turn-js

Usage

Callbacks

Promises

API

myClient = turn(serverAddr, serverPort, user, pwd, transport)

myClient.allocate(function(address) {}, function(error) {})

myClient.allocateP()

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)

Events

0.5.4

7 years ago

0.5.3

7 years ago

0.5.2

7 years ago

0.5.0

7 years ago

0.4.4

7 years ago

0.4.3

7 years ago

0.4.2

8 years ago

0.4.1

8 years ago

0.3.17

8 years ago

0.3.16

8 years ago

0.3.15

8 years ago

0.3.14

8 years ago

0.3.13

8 years ago

0.3.12

8 years ago

0.3.11

8 years ago

0.3.10

8 years ago

0.3.9

8 years ago

0.3.8

8 years ago

0.3.7

8 years ago

0.3.6

8 years ago

0.3.5

8 years ago

0.3.4

8 years ago

0.3.3

8 years ago

0.3.2

8 years ago

0.3.1

8 years ago

0.3.0

8 years ago

0.2.1

8 years ago

0.1.3

8 years ago

0.1.2

8 years ago

0.1.1

8 years ago

0.1.0

8 years ago