@agentdance/node-webrtc-ice 1.0.0 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +40 -0
- package/package.json +3 -2
package/README.md
ADDED
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# @agentdance/node-webrtc-ice
|
|
2
|
+
|
|
3
|
+
RFC 8445 ICE agent for Node.js — part of the [`@agentdance/node-webrtc`](https://github.com/agent-dance/node-webrtc) pure-TypeScript WebRTC stack.
|
|
4
|
+
|
|
5
|
+
## Features
|
|
6
|
+
|
|
7
|
+
- Host / srflx / prflx candidate gathering
|
|
8
|
+
- Connectivity checks with retransmit schedule (0 / 200 / 600 / 1400 / 3800 ms)
|
|
9
|
+
- Aggressive & regular nomination
|
|
10
|
+
- 15 s keepalive, 30 s connect timeout
|
|
11
|
+
- BigInt pair-priority per RFC 8445 §6.1.2.3
|
|
12
|
+
- Zero native dependencies
|
|
13
|
+
|
|
14
|
+
## Install
|
|
15
|
+
|
|
16
|
+
```bash
|
|
17
|
+
npm install @agentdance/node-webrtc-ice
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
## Usage
|
|
21
|
+
|
|
22
|
+
```typescript
|
|
23
|
+
import { IceAgent } from '@agentdance/node-webrtc-ice';
|
|
24
|
+
|
|
25
|
+
const agent = new IceAgent({ role: 'controlling', stunServers: [] });
|
|
26
|
+
await agent.gather();
|
|
27
|
+
agent.setRemoteParameters({ usernameFragment: '…', password: '…' });
|
|
28
|
+
agent.addRemoteCandidate(candidate);
|
|
29
|
+
await agent.connect();
|
|
30
|
+
agent.send(Buffer.from('data'));
|
|
31
|
+
agent.on('data', (buf) => console.log(buf));
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
## Full Documentation
|
|
35
|
+
|
|
36
|
+
See the [main package README](https://github.com/agent-dance/node-webrtc#readme) for the complete API reference, usage examples, and architecture overview.
|
|
37
|
+
|
|
38
|
+
## License
|
|
39
|
+
|
|
40
|
+
MIT
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agentdance/node-webrtc-ice",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.1",
|
|
4
4
|
"description": "RFC 8445 ICE agent — host/srflx/prflx candidates, connectivity checks, nomination. Part of the @agentdance/node-webrtc stack.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"webrtc",
|
|
@@ -34,6 +34,7 @@
|
|
|
34
34
|
}
|
|
35
35
|
},
|
|
36
36
|
"files": [
|
|
37
|
+
"README.md",
|
|
37
38
|
"dist",
|
|
38
39
|
"src"
|
|
39
40
|
],
|
|
@@ -43,7 +44,7 @@
|
|
|
43
44
|
"registry": "https://registry.npmjs.org/"
|
|
44
45
|
},
|
|
45
46
|
"dependencies": {
|
|
46
|
-
"@agentdance/node-webrtc-stun": "1.0.
|
|
47
|
+
"@agentdance/node-webrtc-stun": "1.0.1"
|
|
47
48
|
},
|
|
48
49
|
"devDependencies": {
|
|
49
50
|
"typescript": "*",
|