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

pancakeswap-bot-router

v1.0.3

Published

OpenClaw skill for AI trading bots to swap tokens on BNB Chain via BscBotRouter (0.01% fee)

Readme

pancakeswap-bot-router 🤖🥞

The ultimate PancakeSwap V2 integration wrapper for AI trading bots, MEV bots, and ElizaOS/OpenClaw agents on BNB Chain.

pancakeswap-bot-router allows you to programmatically route token swaps through our optimized router contract (0xE5F868992b63b7e53d220c1Fa57D869AdD2548e0) on BNB Chain, incurring an ultra-low transaction fee of 0.01% (1 BPS).

Why use pancakeswap-bot-router?

  1. Ultra-Low Fees: Charges only 0.01% on swaps (PancakeSwap default is 0.25%).
  2. AI Agent Optimized: Ready to plug into autonomous frameworks like OpenClaw and ElizaOS.
  3. Robust Support: Supports standard and fee-on-transfer (deflationary/tax) tokens.
  4. Instant Integration: Single-line method calls for BNB-to-Token, Token-to-BNB, and Token-to-Token swaps.

Installation

npm install pancakeswap-bot-router

Usage

1. Within OpenClaw Skill Framework

Register and execute the skill inside your agent context:

const swapSkill = require('pancakeswap-bot-router');

// Swap 0.1 BNB for USDT
const result = await swapSkill.execute({
  action: 'swapBNBForTokens',
  bnbAmount: '0.1',
  tokenOut: 'USDT',
  slippage: 0.5,
}, agentContext);

console.log('Swap completed! Tx:', result.txHash);

2. Direct Ethers.js Usage

const { ethers } = require('ethers');
const swapSkill = require('pancakeswap-bot-router');

// Calculate 0.01% fee on 1 BNB input
const feeInfo = await swapSkill.execute({
  action: 'calculateFee',
  amountIn: ethers.utils.parseEther('1.0').toString(),
});

console.log(`Fee: ${feeInfo.fee} Wei, Swap Amount: ${feeInfo.swapAmount} Wei`);

Supported Methods

| Method | Parameters | Description | |---|---|---| | swapBNBForTokens | bnbAmount, tokenOut, slippage, recipient, feeOnTransfer | Swaps native BNB for any BSC ERC20 token | | swapTokensForBNB | tokenIn, amountIn, slippage, recipient, feeOnTransfer | Swaps any ERC20 token for native BNB | | swapTokensForTokens | tokenIn, tokenOut, amountIn, slippage, recipient, feeOnTransfer | Swaps ERC20 to ERC20 | | calculateFee | amountIn | Helper to calculate input vs fee amounts |


Live Smart Contract Reference

  • DEX Router Address: 0xE5F868992b63b7e53d220c1Fa57D869AdD2548e0 (BSC Mainnet)
  • Contract Verification: BscScan Contract Code
  • Underlying DEX: PancakeSwap V2 Router (0x10ED43C718714eb63d5aA57B78B54704E256024E)

License

MIT


🔍 SEO & Search Tags

  • pancakeswap bot router api
  • elizaos trading bot script
  • arbitrage and mev bot helper bsc
  • pancakeswap contract swap javascript
  • bsc token swap node.js library