npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@telnyx/agent-toolkit

v0.1.0

Published

Telnyx Agent Toolkit for TypeScript — tools for OpenAI, Vercel AI SDK, and LangChain.js

Readme

@telnyx/agent-toolkit (TypeScript)

TypeScript toolkit for integrating Telnyx APIs with AI agent frameworks. Provides 18 pre-built tools for messaging, voice, AI, numbers, fax, IoT, and more.

Features

  • Zero runtime dependencies — core uses native fetch() (Node 18+)
  • 18 Telnyx API tools — messaging, voice, numbers, AI, fax, IoT, verification, lookup
  • Framework adapters — OpenAI, Vercel AI SDK, LangChain.js
  • Permission filtering — restrict which tools are available to the agent
  • TypeScript strict mode — full type safety throughout

Installation

npm install @telnyx/agent-toolkit

# Plus your framework of choice:
npm install openai                    # For OpenAI
npm install ai zod                    # For Vercel AI SDK
npm install @langchain/core zod       # For LangChain.js

Quick Start

OpenAI

import { TelnyxAgentToolkit } from "@telnyx/agent-toolkit";
import OpenAI from "openai";

const toolkit = new TelnyxAgentToolkit("YOUR_TELNYX_API_KEY");
const openai = new OpenAI();

const tools = toolkit.getOpenAITools();
const response = await openai.chat.completions.create({
  model: "gpt-4",
  messages: [{ role: "user", content: "Check my account balance" }],
  tools,
});

// Execute tool calls
const executor = toolkit.getOpenAIToolExecutor();
for (const toolCall of response.choices[0].message.tool_calls ?? []) {
  const result = await executor.execute(toolCall);
  console.log(result);
}

Vercel AI SDK

import { TelnyxAgentToolkit } from "@telnyx/agent-toolkit";
import { generateText } from "ai";
import { openai } from "@ai-sdk/openai";

const toolkit = new TelnyxAgentToolkit("YOUR_TELNYX_API_KEY");
const tools = toolkit.getVercelAITools();

const { text } = await generateText({
  model: openai("gpt-4"),
  prompt: "List my phone numbers",
  tools,
});

LangChain.js

import { TelnyxAgentToolkit } from "@telnyx/agent-toolkit";

const toolkit = new TelnyxAgentToolkit("YOUR_TELNYX_API_KEY");
const tools = toolkit.getLangChainTools();
// Use with LangChain agents, chains, etc.

Permission Filtering

Restrict which tools are available:

const toolkit = new TelnyxAgentToolkit("YOUR_TELNYX_API_KEY", {
  configuration: {
    actions: {
      messaging: { send_sms: true, list_messaging_profiles: true },
      numbers: { list: true, search: true },
      account: { get_balance: true },
    },
  },
});

// Only the specified tools will be returned
const tools = toolkit.getOpenAITools(); // 5 tools instead of 18

Available Tools

| Tool | Category | Description | |------|----------|-------------| | send_sms | messaging | Send SMS/MMS messages | | list_messaging_profiles | messaging | List messaging profiles | | create_messaging_profile | messaging | Create messaging profile | | list_phone_numbers | numbers | List account phone numbers | | search_phone_numbers | numbers | Search available numbers | | buy_phone_number | numbers | Purchase a phone number | | get_balance | account | Get account balance | | make_call | voice | Initiate outbound call | | list_connections | voice | List voice connections | | ai_chat | ai | AI chat completion | | ai_embed | ai | Generate embeddings | | list_ai_assistants | ai | List AI assistants | | create_ai_assistant | ai | Create AI assistant | | send_fax | fax | Send a fax | | lookup_number | lookup | Phone number lookup | | list_sim_cards | iot | List IoT SIM cards | | verify_phone | verify | Start phone verification | | verify_code | verify | Check verification code |

Direct API Access

Use the core toolkit for direct tool execution:

const toolkit = new TelnyxAgentToolkit("YOUR_TELNYX_API_KEY");

// Run any tool directly
const result = await toolkit.core.runTool("get_balance", {});
console.log(JSON.parse(result));

Requirements

  • Node.js 18+ (uses native fetch)
  • TypeScript 5.0+ (for development)