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

@layerhop/ai

v0.7.0

Published

LayerHop tools for AI agent frameworks: Vercel AI SDK, LangChain, OpenAI (function calling and Agents SDK). Quotes, unsigned swap transactions, deposit addresses, checkout. Holds no keys and never signs.

Readme

@layerhop/ai

LayerHop tools for AI agents: best-price cross-chain and same-chain swap quotes (EVM chains and Solana), unsigned transactions, simulation, order tracking, token lookup, prices, deposit addresses and checkout. One framework-agnostic tool core with adapters for the Vercel AI SDK, LangChain JS, OpenAI function calling and the OpenAI Agents SDK.

The tools hold no private keys and never sign or broadcast. build_transaction returns unsigned transactions (plus transactionRequests, the ordered approval/swap list) for your own signer or the user's wallet.

npm install @layerhop/ai
# plus the framework you use: ai | @langchain/core | @openai/agents (optional peers)
import { generateText, stepCountIs } from "ai";
import { createVercelTools, AGENT_INSTRUCTIONS } from "@layerhop/ai/vercel";

const tools = createVercelTools({
  integrator: "myapp",          // your partner id: every quote earns your partner fee
  integratorFeeBps: 25,         // optional override (honored with your partner API key)
  apiKey: process.env.LAYERHOP_API_KEY, // optional; needed for deposit addresses and checkout
});

const { text } = await generateText({
  model: "openai/gpt-5",
  system: AGENT_INSTRUCTIONS,
  tools,
  stopWhen: stepCountIs(5),
  prompt: "Quote 100 USDC on Base to SOL. Sender 0xd8dA...6045, recipient 9WzD...AWWM.",
});

Other adapters:

import { createLangChainTools } from "@layerhop/ai/langchain";        // DynamicStructuredTool[]
import { createOpenAITools } from "@layerhop/ai/openai";              // { chatCompletionsTools, responsesTools, handleToolCall }
import { createOpenAIAgentsTools } from "@layerhop/ai/openai-agents"; // FunctionTool[] for @openai/agents
import { createLayerHopTools } from "@layerhop/ai";                   // plain { name, description, schema, execute, run }

Tools: list_chains, list_tokens, get_prices, get_quote, build_transaction, simulate_transaction, report_submitted, get_order_status, get_swap_link, create_deposit_address, get_deposit_address, create_checkout_session. Amounts in tool inputs are human decimals ("100" = 100 USDC). Quotes use the api fee channel.

Tested with ai 7.0.127, @langchain/core 1.2.12 and @openai/agents 0.18.0. ElizaOS, Coinbase AgentKit and GOAT have their own packages: @layerhop/plugin-elizaos, @layerhop/agentkit, @layerhop/goat.

Guide: https://docs.layerhop.com/guides/agent-frameworks

MIT licensed.