Skip to content

feat(tools): Add Nory x402 payment tools#7216

Open
TheMemeBanker wants to merge 1 commit intomicrosoft:mainfrom
TheMemeBanker:add-nory-x402-tools
Open

feat(tools): Add Nory x402 payment tools#7216
TheMemeBanker wants to merge 1 commit intomicrosoft:mainfrom
TheMemeBanker:add-nory-x402-tools

Conversation

@TheMemeBanker
Copy link

Summary

Adds tools for AI agents to make payments using the x402 HTTP payment protocol via Nory.

New Tools

Tool Description
NoryPaymentRequirementsTool Get payment requirements for a resource (amount, supported networks, wallet address)
NoryVerifyPaymentTool Verify a signed payment transaction before settlement
NorySettlePaymentTool Submit a verified payment to the blockchain (~400ms)
NoryTransactionLookupTool Check the status of a previously submitted payment
NoryHealthCheckTool Check Nory service health and supported networks

Supported Networks

  • Solana (mainnet/devnet)
  • Base, Polygon, Arbitrum, Optimism, Avalanche, Sei, IoTeX (all mainnet)

Use Cases

AI agents can now:

  • Pay for premium API access on-the-fly
  • Handle HTTP 402 Payment Required responses automatically
  • Make micropayments for AI-to-AI services
  • Access paid resources without pre-configured subscriptions

Usage Example

from autogen_agentchat.agents import AssistantAgent
from autogen_ext.tools.nory import NoryPaymentRequirementsTool

# Create the payment tool
payment_tool = NoryPaymentRequirementsTool(api_key="optional-api-key")

# Add to an agent
assistant = AssistantAgent(
    "payment_agent",
    model_client=model,
    tools=[payment_tool]
)

Documentation

🤖 Generated with Claude Code

Adds tools for AI agents to make payments using the x402 HTTP protocol via Nory.

New tools:
- NoryPaymentRequirementsTool: Get payment requirements for a resource
- NoryVerifyPaymentTool: Verify signed payment transactions
- NorySettlePaymentTool: Submit payments for on-chain settlement
- NoryTransactionLookupTool: Check transaction status
- NoryHealthCheckTool: Check service health

Features:
- Supports Solana and 7 EVM chains
- Sub-400ms payment settlement
- Optional API key authentication
- Async HTTP requests with httpx

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@elreynegro
Copy link

elreynegro commented Feb 6, 2026 via email

@TheMemeBanker
Copy link
Author

Hi team! Following up on this PR for Nory x402 payment tools. This would enable AutoGen agents to handle HTTP 402 Payment Required responses and make blockchain payments autonomously. Let me know if there are any changes needed to meet Microsoft's contribution guidelines!

@TheMemeBanker
Copy link
Author

@microsoft-github-policy-service agree

@TheMemeBanker
Copy link
Author

Update: nory-mcp-server is now live in the official MCP registry (io.github.TheMemeBanker/nory-x402). This AutoGen integration would provide the same payment capabilities through Python tools. The x402 protocol enables agents to autonomously pay for APIs, data, and services - a valuable capability for production agent deployments. Happy to address any feedback!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants