@framers/agentos-ext-voice-telnyx 0.1.3 → 0.1.5

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 ADDED
@@ -0,0 +1,79 @@
1
+ # Telnyx voice calls
2
+
3
+ This pack gives an agent a phone call tool and voice provider using the `telnyx` SDK and Telnyx Call Control. It places outbound calls, speaks text into calls, hangs up calls and normalizes webhook events.
4
+
5
+ ## Installation
6
+
7
+ ```bash
8
+ npm install @framers/agentos-ext-voice-telnyx
9
+ ```
10
+
11
+ Peer dependency: `@framers/agentos` (`>=0.10.40`).
12
+
13
+ ## Usage
14
+
15
+ ```ts
16
+ import { AgentOS } from '@framers/agentos';
17
+
18
+ const agentos = await AgentOS.create({
19
+ extensionManifest: {
20
+ packs: [
21
+ {
22
+ package: '@framers/agentos-ext-voice-telnyx',
23
+ options: {
24
+ apiKey: process.env.TELNYX_API_KEY,
25
+ connectionId: process.env.TELNYX_CONNECTION_ID,
26
+ publicKey: process.env.TELNYX_PUBLIC_KEY,
27
+ fromNumber: process.env.TELNYX_FROM_NUMBER,
28
+ },
29
+ },
30
+ ],
31
+ },
32
+ });
33
+ ```
34
+
35
+ ## Configuration
36
+
37
+ Credentials resolve from direct options, then `options.secrets`, then the listed environment variables in order.
38
+
39
+ | Option | Secret id | Environment variable | Required | Default |
40
+ | --- | --- | --- | --- | --- |
41
+ | `apiKey` | `telnyx.apiKey` | `TELNYX_API_KEY`, `TELNYX_API_V2_KEY` | Yes | None, throws if absent |
42
+ | `connectionId` | `telnyx.connectionId` | `TELNYX_CONNECTION_ID`, `TELNYX_APP_ID` | Yes | None, throws if absent |
43
+ | `publicKey` | `telnyx.publicKey` | `TELNYX_PUBLIC_KEY` | No | `undefined` |
44
+ | `fromNumber` | None | `TELNYX_FROM_NUMBER` | No | `undefined` in service, empty string in manager config |
45
+ | `webhookBaseUrl` | None | None | No | `undefined` |
46
+ | `priority` | None | None | No | `50` |
47
+ | `secrets` | Map containing the secret ids above | None | No | `undefined` |
48
+
49
+ ## Tools
50
+
51
+ | Tool | What it does |
52
+ | --- | --- |
53
+ | `telnyxVoiceCall` | Makes and manages phone calls via Telnyx, including outbound calling, in-call TTS, hangup and status queries. |
54
+
55
+ ### `telnyxVoiceCall` parameters
56
+
57
+ | Parameter | Type | Required | Description |
58
+ | --- | --- | --- | --- |
59
+ | `action` | `string`, enum: `call`, `speak`, `hangup`, `status`, `list` | Yes | The voice call action to perform |
60
+ | `toNumber` | `string` | No | E.164 phone number to call (required for "`call`" action) |
61
+ | `message` | `string` | No | Message to speak (for "`call`" in notify mode, or "`speak`" action) |
62
+ | `mode` | `string`, enum: `notify`, `conversation` | No | Call interaction mode (default: "`conversation`") |
63
+ | `callId` | `string` | No | Call ID (required for "`speak`", "`hangup`", and "`status`" actions) |
64
+
65
+ ## Notes
66
+
67
+ The package requires Node.js `>=22`. Activation dynamically loads the SDK and initializes the service. Deactivation disposes the call manager and releases the SDK client reference.
68
+
69
+ The tool has side effects: `call` places a phone call, `speak` sends a TTS command and `hangup` ends a call. Runtime checks require `toNumber` for `call`, `callId` and `message` for `speak`, and `callId` for `hangup` or `status`. The schema requires only `action`.
70
+
71
+ The provider uses the configured connection ID, caller number and webhook URL. `notify` enables answering machine detection. `conversation` passes a media stream URL with the inbound track. Call state is encoded into the outbound request. The service defaults TTS to a female voice and `en-US` with a text payload.
72
+
73
+ The provider parses call initiation, answer, hangup, machine detection and stream connection events. It attempts signature verification when `publicKey` is set and rejects missing signature headers, failed verification or timestamps outside its freshness window. Without `publicKey`, it accepts webhooks without signature verification.
74
+
75
+ The pack registers `voice-provider` named `telnyx` and delegates call management to `CallManager`. Its files do not start an HTTP webhook listener or implement a media socket server.
76
+
77
+ ## License
78
+
79
+ Apache-2.0
package/manifest.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "$schema": "https://agentos.sh/schemas/extension-manifest-v1.json",
3
3
  "id": "com.framers.voice.telnyx",
4
4
  "name": "Telnyx Voice Call Extension",
5
- "version": "0.1.3",
5
+ "version": "0.1.5",
6
6
  "description": "Telnyx telephony provider for voice calls via Call Control v2 — outbound/inbound calls, TTS speak commands, and bidirectional media streaming.",
7
7
  "categories": ["voice", "telephony"],
8
8
  "platforms": ["telnyx"],
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@framers/agentos-ext-voice-telnyx",
3
- "version": "0.1.3",
3
+ "version": "0.1.5",
4
4
  "description": "Telnyx voice call provider for AgentOS — outbound/inbound calls via Telnyx Call Control v2",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -15,7 +15,7 @@
15
15
  "name": "Framers AI",
16
16
  "url": "https://frame.dev"
17
17
  },
18
- "license": "MIT",
18
+ "license": "Apache-2.0",
19
19
  "files": [
20
20
  "dist",
21
21
  "manifest.json"
@@ -30,7 +30,7 @@
30
30
  "@types/node": "^20.0.0",
31
31
  "typescript": "^5.0.0",
32
32
  "vitest": "^3.2.7",
33
- "@framers/agentos": "^0.10.40"
33
+ "@framers/agentos": "^0.13.47"
34
34
  },
35
35
  "engines": {
36
36
  "node": ">=22"