Agentkit
Agentkit is how an AI agent gets a wallet (KMS-custodied, policy-enforced, no private key in your process) and hands (the ability to pay for real work on the internet — browse, search, scrape, call paid APIs — settled gaslessly by the 0xGasless facilitator).
There are two packages, and they are layers of the same stack — not competitors. Pick by how your agent is built:
@0xgasless/agentkit | @0xgasless/agent | |
|---|---|---|
| What it is | LangChain / LangGraph tools an LLM can call | The direct TypeScript client underneath |
| Who decides | The model (“find a tool that reads web pages, run it”) | Your code (client.x402.payFetch(url)) |
| Use when | You’re building an LLM agent loop | You’re writing the logic yourself — bots, services, backends |
| Includes | Everything below, wrapped as ~37 actions | Agents, x402 signing/paying, payFetch, identity, policy |
| Docs | This section | Agent SDK section |
Both share the same agent wallet, the same server-enforced spending policy, and
the same Tool Gateway. Agentkit depends on
@0xgasless/agent — using one never locks you out of the other.
npm install @0xgasless/agentkit # LLM tools (includes the client)npm install @0xgasless/agent # just the client, no LangChainWhat an agent can do
Section titled “What an agent can do”Pay — send USDC/XSGD and pay any x402 API on the internet, gaslessly, under spend caps. The agent needs zero native gas token; the facilitator pays the gas.
Do — search and run tools from the Tool Gateway (backed by Apify’s 57k-actor marketplace): browse the web, run search, scrape pages — paid per call from the agent’s wallet.
Be trusted — mint an ERC-8004 on-chain identity, check another agent’s reputation before paying it, and leave feedback after.
DeFi — balances, transfers, swaps and bridges through gasless ERC-4337 smart accounts (self-custody mode).
Two modes
Section titled “Two modes”| Mode | Wallet | Use when |
|---|---|---|
| Platform (recommended) | KMS-custodied by 0xGasless; policy-enforced; no key in your code | You want payments, tools, identity, spend limits, audit |
| Self-custody | A local private key via an ERC-4337 smart account | You hold the key and want classic gasless DeFi actions |
Where to go next
Section titled “Where to go next”- Getting Started — a paying agent in 5 minutes.
- Payments actions —
x402_pay,pay_api, spend status. - Tool actions —
search_tools,call_tool,browse_web. - Trust actions — identity, reputation, feedback.
- Agent SDK — the
@0xgasless/agentclient reference.