LangChain tools for Revettr counterparty risk scoring in agentic commerce
Project description
langchain-revettr
LangChain tools for Revettr counterparty risk scoring. Score wallets, domains, IPs, and companies 0-100 before sending payments in agentic commerce.
Install
pip install langchain-revettr
# With x402 auto-payment:
pip install langchain-revettr[x402]
Tools
ScoreCounterpartyTool
Score any counterparty 0-100 with per-signal breakdown.
from langchain_revettr import ScoreCounterpartyTool
tool = ScoreCounterpartyTool(wallet_private_key="0x...") # Optional: for x402 payment
result = tool.invoke({"domain": "uniswap.org"})
print(result)
# Score: 92/100 (tier: low, confidence: 0.75)
# Flags: none
# Signals checked: 3
ShouldPayTool
Get a clear YES/NO/WARN decision before sending payment.
from langchain_revettr import ShouldPayTool
tool = ShouldPayTool(wallet_private_key="0x...")
result = tool.invoke({"url": "https://some-api.com", "min_score": 60})
print(result)
# Decision: YES
# Counterparty scored 92/100 (low risk) — safe to proceed.
With a LangChain Agent
from langchain_openai import ChatOpenAI
from langchain.agents import AgentExecutor, create_tool_calling_agent
from langchain_revettr import ScoreCounterpartyTool, ShouldPayTool
tools = [ScoreCounterpartyTool(), ShouldPayTool()]
llm = ChatOpenAI(model="gpt-4")
agent = create_tool_calling_agent(llm, tools, prompt)
executor = AgentExecutor(agent=agent, tools=tools)
result = executor.invoke({"input": "Should I pay the service at sketchy-crypto.xyz?"})
Pricing
$0.01 USDC per score via x402 on Base. No API keys needed.
Links
- Revettr API
- revettr SDK
- MCP Server — works with Claude Desktop, Cursor, CrewAI
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file langchain_revettr-0.1.0.tar.gz.
File metadata
- Download URL: langchain_revettr-0.1.0.tar.gz
- Upload date:
- Size: 4.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ca16a7fa46f05cc966c378e9ec0d80eb3f504fb05ee0d2c18da202dbd3824bbe
|
|
| MD5 |
a045619dab1fc57997d88d63b26fbcfc
|
|
| BLAKE2b-256 |
658ae2774dc16d996821cd9155ddb3c6a77d3cd42713d29976d4eacebc0a61b7
|
File details
Details for the file langchain_revettr-0.1.0-py3-none-any.whl.
File metadata
- Download URL: langchain_revettr-0.1.0-py3-none-any.whl
- Upload date:
- Size: 5.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
146bcd083d283de3fce5dbf502c18ce30fc668ec3e7da3eedb720b848fbe1292
|
|
| MD5 |
7b81f6127b34f377010b83f3f3e36244
|
|
| BLAKE2b-256 |
fbc0cffe68b555f1dd25c2496e54b0b2809c82445ca07d702b313e6b49a9e0c8
|