rdx-data-mcp 2.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,12 @@
1
+ __pycache__/
2
+ *.py[cod]
3
+ *.egg-info/
4
+ .venv/
5
+ venv/
6
+ build/
7
+ dist/
8
+ .pytest_cache/
9
+ .ruff_cache/
10
+ .mypy_cache/
11
+ .env
12
+ .env.*
@@ -0,0 +1,13 @@
1
+ FROM python:3.12-slim
2
+
3
+ ENV PYTHONUNBUFFERED=1 \
4
+ PIP_NO_CACHE_DIR=1 \
5
+ PIP_DISABLE_PIP_VERSION_CHECK=1
6
+
7
+ WORKDIR /app
8
+ COPY pyproject.toml README.md LICENSE ./
9
+ COPY src ./src
10
+ RUN pip install .
11
+
12
+ # stdio MCP server: the client (Smithery, Glama, ...) attaches to stdin/stdout.
13
+ CMD ["rdx-data-mcp"]
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 RDX Data Network
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,303 @@
1
+ Metadata-Version: 2.5
2
+ Name: rdx-data-mcp
3
+ Version: 2.1.0
4
+ Summary: MCP server giving AI agents pay-per-call access to the RDX Data Network (rdxdata.xyz), settled via Skyfire or Base USDC (x402).
5
+ Project-URL: Homepage, https://rdxdata.xyz
6
+ Author: RDX Data Network
7
+ License-Expression: MIT
8
+ License-File: LICENSE
9
+ Keywords: ai-agents,base,crypto-data,mcp,micropayments,model-context-protocol,skyfire,usdc,x402
10
+ Classifier: Development Status :: 4 - Beta
11
+ Classifier: Intended Audience :: Developers
12
+ Classifier: Programming Language :: Python :: 3
13
+ Classifier: Programming Language :: Python :: 3.10
14
+ Classifier: Programming Language :: Python :: 3.11
15
+ Classifier: Programming Language :: Python :: 3.12
16
+ Classifier: Programming Language :: Python :: 3.13
17
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
18
+ Requires-Python: >=3.10
19
+ Requires-Dist: httpx>=0.27.0
20
+ Requires-Dist: mcp>=1.2.0
21
+ Requires-Dist: pydantic>=2.0.0
22
+ Requires-Dist: web3>=6.15.0
23
+ Provides-Extra: dev
24
+ Requires-Dist: pytest>=8.0; extra == 'dev'
25
+ Description-Content-Type: text/markdown
26
+
27
+ # rdx-data-mcp
28
+
29
+ An [MCP](https://modelcontextprotocol.io) server that gives autonomous AI agents (Claude Code, Claude Desktop, Cursor, Windsurf, OpenAI Agents) one tool gateway to the **RDX Data Network** at [rdxdata.xyz](https://rdxdata.xyz): live crypto and macro data, Web3 security, web utilities, commodities and travel.
30
+
31
+ Agents discover the tools for free, then pay per call (from **$0.001 to $0.10 USDC**) with no human in the loop. Payment is settled under the hood through either rail:
32
+
33
+ - **Skyfire**: set `SKYFIRE_API_KEY`. Supports `kya` (free preview), `pay` and `kya-pay` tokens.
34
+ - **Coinbase x402 v2 / AgentCash**: set `BUYER_PRIVATE_KEY`. Pays in USDC on Base mainnet.
35
+
36
+ > **25 paid tools across 23 `*.rdxdata.xyz` services, plus 1 free discovery tool** (`list_rdx_catalog`).
37
+ > Two services expose two tools each: `sandbox` (math + quant) and `macro-fx` (FX rates + conversion).
38
+
39
+ ## What's new in 2.1.0
40
+
41
+ - **`macro-fx.rdxdata.xyz`**: `get_global_fx_and_macro_rates` and `convert_fiat_currency_pair` (the RDX Global FX & Macro Oracle).
42
+ - **`doc-parse.rdxdata.xyz`**: `parse_remote_pdf_document`.
43
+ - **`domain-trust.rdxdata.xyz`**: `audit_domain_trust_and_ssl`.
44
+ - Request timeout raised from 20 s to 25 s.
45
+
46
+ ## Services and tools
47
+
48
+ ### Market & Trading Alpha
49
+
50
+ | Tool | Service | Cost (USDC) | What it returns |
51
+ |---|---|---|---|
52
+ | `get_crypto_market_pulse` | `pulse` | $0.001 (free with Skyfire KYA) | BTC/ETH/SOL prices, Fear & Greed Index, dominance |
53
+ | `get_global_fx_and_macro_rates` | `macro-fx` | $0.005 | ECB and central-bank FX rates plus World Bank CPI inflation and GDP growth |
54
+ | `convert_fiat_currency_pair` | `macro-fx` | $0.005 | Exact cross-rate conversion between two fiat currencies |
55
+ | `get_expired_domains_alpha` | `domains` | $0.02 | AI-scored high-value pending-delete domains |
56
+ | `get_social_sentiment_velocity` | `sentiment` | $0.03 | Hacker News, GitHub and crypto narrative velocity |
57
+ | `get_web3_grants_and_airdrop_alpha` | `alpha` | $0.03 | Tokenless high-TVL protocols and open dev bounties |
58
+ | `get_prediction_market_arbitrage` | `predict` | $0.05 | Polymarket vs Kalshi matched-event spreads |
59
+ | `get_rwa_premium_analytics` | `rwa` | $0.05 | Ondo / PAXG NAV premium or discount and liquidity |
60
+ | `get_dex_stablecoin_arbitrage` | `dex` | $0.05 | Cross-chain USDC/USDT de-pegs and DEX routes |
61
+ | `get_funding_rate_arbitrage` | `funding` | $0.10 | BTC/ETH/SOL perp funding spreads (Binance, Hyperliquid, dYdX) |
62
+
63
+ ### Web3 Security & Infrastructure
64
+
65
+ | Tool | Service | Cost (USDC) | What it returns |
66
+ |---|---|---|---|
67
+ | `score_web3_wallet_intelligence` | `wallet-intel` | $0.01 | Base/ETH balance, tx history, Sybil and persona trust score |
68
+ | `get_cross_chain_gas_and_mev_oracle` | `gas` | $0.01 | Base, Arbitrum, Optimism, Solana, ETH gas and MEV risk |
69
+ | `audit_smart_contract_security` | `security` | $0.02 | Base/Solana honeypot and rug-pull scanner |
70
+ | `get_depin_gpu_compute_prices` | `compute` | $0.02 | H100, A100, RTX 4090 prices across io.net, Akash, Render |
71
+
72
+ ### AI & Web Utilities
73
+
74
+ | Tool | Service | Cost (USDC) | What it returns |
75
+ |---|---|---|---|
76
+ | `evaluate_math_or_quant_expression` | `sandbox` | $0.002 | Deterministic SymPy/NumPy math results |
77
+ | `calculate_quant_finance_model` | `sandbox` | $0.002 | Kelly Criterion, AMM slippage, compound APY, Black-Scholes |
78
+ | `extract_clean_web_markdown` | `reader` | $0.005 | Any webpage as clean, LLM-ready Markdown |
79
+ | `audit_package_dependency` | `deps` | $0.005 | CVEs via OSV.dev plus latest registry version |
80
+ | `audit_domain_trust_and_ssl` | `domain-trust` | $0.005 | RDAP domain age, TLS/SSL validity, SPF/DMARC, URLhaus phishing status |
81
+ | `parse_remote_pdf_document` | `doc-parse` | $0.01 | Page-by-page text and metadata from any public PDF URL |
82
+ | `verify_citation_or_url` | `verify` | $0.01 | URL liveness and Crossref/Wikipedia grounding |
83
+ | `check_product_price_and_stock` | `price-watch` | $0.01 | Real-time Schema.org/OpenGraph price and inventory |
84
+ | `get_llm_cost_routing_recommendations` | `llm-router` | $0.01 | Cheapest high-performing LLM per task |
85
+
86
+ ### Commodities & Travel
87
+
88
+ | Tool | Service | Cost (USDC) | What it returns |
89
+ |---|---|---|---|
90
+ | `get_global_coffee_commodities` | `coffee` | $0.01 | Arabica, Robusta, Vietnam farmgate (VND/kg) |
91
+ | `get_travel_flash_deals` | `travel` | $0.05 | Flight error fares and hotel discounts |
92
+
93
+ Every service lives at `https://<service>.rdxdata.xyz`. Call `list_rdx_catalog` first (free): it returns every endpoint, price and data-freshness note, and reports whether a payment method is configured.
94
+
95
+ ## Install
96
+
97
+ ```bash
98
+ # no install needed with uv
99
+ uvx rdx-data-mcp
100
+
101
+ # or with pip
102
+ pip install rdx-data-mcp
103
+ rdx-data-mcp
104
+ ```
105
+
106
+ Python 3.10+. Set `SKYFIRE_API_KEY`, `BUYER_PRIVATE_KEY`, or both (Skyfire is tried first). Blank values are treated as unset.
107
+
108
+ ### Claude Desktop
109
+
110
+ Edit `claude_desktop_config.json` (macOS: `~/Library/Application Support/Claude/`, Windows: `%APPDATA%\Claude\`):
111
+
112
+ ```json
113
+ {
114
+ "mcpServers": {
115
+ "rdx-data": {
116
+ "command": "uvx",
117
+ "args": ["rdx-data-mcp"],
118
+ "env": {
119
+ "SKYFIRE_API_KEY": "your_skyfire_buyer_agent_api_key",
120
+ "BUYER_PRIVATE_KEY": "",
121
+ "BASE_RPC_URL": "https://rpc.ankr.com/base"
122
+ }
123
+ }
124
+ }
125
+ }
126
+ ```
127
+
128
+ ### Claude Code
129
+
130
+ ```bash
131
+ claude mcp add rdx-data -e SKYFIRE_API_KEY=your_skyfire_buyer_agent_api_key -- uvx rdx-data-mcp
132
+ ```
133
+
134
+ ### Cursor
135
+
136
+ Add to `~/.cursor/mcp.json` (or `.cursor/mcp.json` in a project):
137
+
138
+ ```json
139
+ {
140
+ "mcpServers": {
141
+ "rdx-data": {
142
+ "command": "uvx",
143
+ "args": ["rdx-data-mcp"],
144
+ "env": {
145
+ "BUYER_PRIVATE_KEY": "0xyour_dedicated_wallet_private_key"
146
+ }
147
+ }
148
+ }
149
+ }
150
+ ```
151
+
152
+ ### Windsurf
153
+
154
+ Add to `~/.codeium/windsurf/mcp_config.json`:
155
+
156
+ ```json
157
+ {
158
+ "mcpServers": {
159
+ "rdx-data": {
160
+ "command": "uvx",
161
+ "args": ["rdx-data-mcp"],
162
+ "env": {
163
+ "SKYFIRE_API_KEY": "your_skyfire_buyer_agent_api_key"
164
+ }
165
+ }
166
+ }
167
+ }
168
+ ```
169
+
170
+ ### pip install (any client)
171
+
172
+ ```json
173
+ {
174
+ "mcpServers": {
175
+ "rdx-data": {
176
+ "command": "rdx-data-mcp",
177
+ "env": {
178
+ "SKYFIRE_API_KEY": "your_skyfire_buyer_agent_api_key"
179
+ }
180
+ }
181
+ }
182
+ }
183
+ ```
184
+
185
+ ### OpenAI Agents SDK
186
+
187
+ ```python
188
+ from agents import Agent
189
+ from agents.mcp import MCPServerStdio
190
+
191
+ async with MCPServerStdio(
192
+ params={"command": "uvx", "args": ["rdx-data-mcp"], "env": {"SKYFIRE_API_KEY": "..."}}
193
+ ) as rdx:
194
+ agent = Agent(name="Analyst", instructions="Use RDX tools for live data.", mcp_servers=[rdx])
195
+ ```
196
+
197
+ ## Pricing
198
+
199
+ Every call is priced in USDC. There is no subscription.
200
+
201
+ | Price per call | Tools |
202
+ |---|---|
203
+ | **Free** | `list_rdx_catalog` |
204
+ | $0.001 (free with Skyfire KYA) | `get_crypto_market_pulse` |
205
+ | $0.002 | `evaluate_math_or_quant_expression`, `calculate_quant_finance_model` |
206
+ | $0.005 | `extract_clean_web_markdown`, `audit_package_dependency`, `audit_domain_trust_and_ssl`, `get_global_fx_and_macro_rates`, `convert_fiat_currency_pair` |
207
+ | $0.01 | `parse_remote_pdf_document`, `verify_citation_or_url`, `check_product_price_and_stock`, `score_web3_wallet_intelligence`, `get_cross_chain_gas_and_mev_oracle`, `get_llm_cost_routing_recommendations`, `get_global_coffee_commodities` |
208
+ | $0.02 | `audit_smart_contract_security`, `get_depin_gpu_compute_prices`, `get_expired_domains_alpha` |
209
+ | $0.03 | `get_social_sentiment_velocity`, `get_web3_grants_and_airdrop_alpha` |
210
+ | $0.05 | `get_prediction_market_arbitrage`, `get_rwa_premium_analytics`, `get_dex_stablecoin_arbitrage`, `get_travel_flash_deals` |
211
+ | $0.10 | `get_funding_rate_arbitrage` |
212
+
213
+ ### Free `kya` preview tier
214
+
215
+ A Skyfire `kya` (identity-only) token costs nothing. `get_crypto_market_pulse` always uses one. Several other services also return a free preview or sample to `kya` tokens (for example FX majors on `macro-fx`, a PDF preview on `doc-parse`, a two-chain sample on `gas`). By default the server requests full paid results with a `kya-pay` token; set `RDX_SKYFIRE_TOKEN_TYPE=kya` to request previews on every call instead.
216
+
217
+ ## Funding a payment method
218
+
219
+ ### Option A: Skyfire (recommended)
220
+
221
+ 1. Create an account at [skyfire.xyz](https://skyfire.xyz) and a **Buyer agent** (docs: [docs.skyfire.xyz](https://docs.skyfire.xyz)).
222
+ 2. Fund the Buyer agent's wallet with USDC.
223
+ 3. Copy the Buyer agent API key into `SKYFIRE_API_KEY`.
224
+
225
+ The server asks Skyfire for a token sized to the call price and sends it to the RDX service in the `kyapay-token` header.
226
+
227
+ Skyfire tokens for services listed in the Skyfire Directory need the seller's service ID unless your Skyfire account belongs to an organization. Provide IDs with `RDX_SKYFIRE_SERVICE_IDS`, a JSON map keyed by sub-domain, for example `{"pulse": "<service-id>", "macro-fx": "<service-id>", "doc-parse": "<service-id>"}`. If Skyfire fails for any reason, the server falls back to x402 when `BUYER_PRIVATE_KEY` is set.
228
+
229
+ ### Option B: Base USDC wallet (x402 / AgentCash)
230
+
231
+ 1. Create a **dedicated wallet** for the agent. Never reuse a main wallet.
232
+ 2. Send it USDC on **Base mainnet** (contract `0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913`) plus a few cents of ETH on Base for gas. Most exchanges that support Base withdrawals work.
233
+ 3. Put the wallet's private key in `BUYER_PRIVATE_KEY`.
234
+
235
+ ## How payment works
236
+
237
+ 1. Skyfire first: if `SKYFIRE_API_KEY` is set, a token is created and the request is sent with `kyapay-token`.
238
+ 2. If Skyfire is not configured, or the service answers 401/402, the request is sent unauthenticated.
239
+ 3. On HTTP 402 the invoice (`asset`, `payTo`, `amount`) is decoded from the Base64 `Payment-Required` header, or from the JSON body.
240
+ 4. No `BUYER_PRIVATE_KEY`: the tool returns a structured `payment_required` result with the decoded invoice and exact setup steps.
241
+ 5. With `BUYER_PRIVATE_KEY`: an ERC-20 USDC `transfer` is sent on Base (chain id 8453), the server waits 6 seconds, then retries the identical request with `X-402-Payment-Receipt: <tx hash>`.
242
+
243
+ Every request times out after 25 seconds. Successful results include an `_rdx_payment` field showing the protocol used and, for x402, the transaction hash. If a payment is sent but the service has not accepted the receipt yet, the tool says so and an identical retry re-submits the saved receipt instead of paying again.
244
+
245
+ ## Safety
246
+
247
+ An autonomous wallet needs guard rails, so these are built in:
248
+
249
+ - Only `https://*.rdxdata.xyz` is ever called or paid.
250
+ - Only **USDC on Base mainnet** is ever sent. Testnet or other-asset invoices are refused.
251
+ - Each payment is capped at **0.25 USDC** by default (`RDX_MAX_PAYMENT_USDC`). Larger invoices are refused and nothing is paid.
252
+ - On-chain sends are serialized so concurrent calls cannot collide on the wallet nonce.
253
+ - Private keys and Skyfire keys are never logged or returned in results. Logs go to stderr.
254
+ - Tool inputs are validated before any request is made.
255
+
256
+ Use a wallet that holds only what you are willing to spend.
257
+
258
+ ## Configuration
259
+
260
+ | Variable | Default | Purpose |
261
+ |---|---|---|
262
+ | `SKYFIRE_API_KEY` | unset | Skyfire Buyer agent API key (payment rail 1) |
263
+ | `BUYER_PRIVATE_KEY` | unset | Hex private key of a Base wallet holding USDC (payment rail 2) |
264
+ | `BASE_RPC_URL` | `https://rpc.ankr.com/base` | Base mainnet RPC. `https://mainnet.base.org` is used as a fallback |
265
+ | `RDX_MAX_PAYMENT_USDC` | `0.25` | Per-call payment cap |
266
+ | `RDX_SKYFIRE_TOKEN_TYPE` | auto | Force `kya`, `pay` or `kya-pay` for every call |
267
+ | `RDX_SKYFIRE_SERVICE_IDS` | unset | JSON map of sub-domain to Skyfire seller service ID |
268
+ | `SKYFIRE_API_BASE` | `https://api.skyfire.xyz` | Skyfire API base URL |
269
+ | `RDX_ALLOW_CUSTOM_HOSTS` | unset | Set to `1` to allow non-rdxdata.xyz hosts (self-hosting, testing) |
270
+ | `RDX_LOG_LEVEL` | `WARNING` | Log level (stderr) |
271
+
272
+ ## Development
273
+
274
+ ```bash
275
+ python -m venv .venv && source .venv/bin/activate
276
+ pip install -e ".[dev]"
277
+ pytest -q
278
+
279
+ # try it interactively
280
+ npx @modelcontextprotocol/inspector rdx-data-mcp
281
+ ```
282
+
283
+ Layout:
284
+
285
+ ```
286
+ src/rdx_data_mcp/
287
+ catalog.py endpoints, prices, categories (single source of truth)
288
+ payment.py Skyfire + x402 payment client
289
+ server.py MCP server and the 26 tools
290
+ tests/ payment-flow and tool-mapping tests (no network needed)
291
+ ```
292
+
293
+ ## Publishing
294
+
295
+ ```bash
296
+ python -m build && twine check dist/* && twine upload dist/*
297
+ ```
298
+
299
+ Smithery reads `smithery.yaml` and the `Dockerfile` from the repository root. Glama.ai and mcp.so index the public repository.
300
+
301
+ ## License
302
+
303
+ MIT
@@ -0,0 +1,277 @@
1
+ # rdx-data-mcp
2
+
3
+ An [MCP](https://modelcontextprotocol.io) server that gives autonomous AI agents (Claude Code, Claude Desktop, Cursor, Windsurf, OpenAI Agents) one tool gateway to the **RDX Data Network** at [rdxdata.xyz](https://rdxdata.xyz): live crypto and macro data, Web3 security, web utilities, commodities and travel.
4
+
5
+ Agents discover the tools for free, then pay per call (from **$0.001 to $0.10 USDC**) with no human in the loop. Payment is settled under the hood through either rail:
6
+
7
+ - **Skyfire**: set `SKYFIRE_API_KEY`. Supports `kya` (free preview), `pay` and `kya-pay` tokens.
8
+ - **Coinbase x402 v2 / AgentCash**: set `BUYER_PRIVATE_KEY`. Pays in USDC on Base mainnet.
9
+
10
+ > **25 paid tools across 23 `*.rdxdata.xyz` services, plus 1 free discovery tool** (`list_rdx_catalog`).
11
+ > Two services expose two tools each: `sandbox` (math + quant) and `macro-fx` (FX rates + conversion).
12
+
13
+ ## What's new in 2.1.0
14
+
15
+ - **`macro-fx.rdxdata.xyz`**: `get_global_fx_and_macro_rates` and `convert_fiat_currency_pair` (the RDX Global FX & Macro Oracle).
16
+ - **`doc-parse.rdxdata.xyz`**: `parse_remote_pdf_document`.
17
+ - **`domain-trust.rdxdata.xyz`**: `audit_domain_trust_and_ssl`.
18
+ - Request timeout raised from 20 s to 25 s.
19
+
20
+ ## Services and tools
21
+
22
+ ### Market & Trading Alpha
23
+
24
+ | Tool | Service | Cost (USDC) | What it returns |
25
+ |---|---|---|---|
26
+ | `get_crypto_market_pulse` | `pulse` | $0.001 (free with Skyfire KYA) | BTC/ETH/SOL prices, Fear & Greed Index, dominance |
27
+ | `get_global_fx_and_macro_rates` | `macro-fx` | $0.005 | ECB and central-bank FX rates plus World Bank CPI inflation and GDP growth |
28
+ | `convert_fiat_currency_pair` | `macro-fx` | $0.005 | Exact cross-rate conversion between two fiat currencies |
29
+ | `get_expired_domains_alpha` | `domains` | $0.02 | AI-scored high-value pending-delete domains |
30
+ | `get_social_sentiment_velocity` | `sentiment` | $0.03 | Hacker News, GitHub and crypto narrative velocity |
31
+ | `get_web3_grants_and_airdrop_alpha` | `alpha` | $0.03 | Tokenless high-TVL protocols and open dev bounties |
32
+ | `get_prediction_market_arbitrage` | `predict` | $0.05 | Polymarket vs Kalshi matched-event spreads |
33
+ | `get_rwa_premium_analytics` | `rwa` | $0.05 | Ondo / PAXG NAV premium or discount and liquidity |
34
+ | `get_dex_stablecoin_arbitrage` | `dex` | $0.05 | Cross-chain USDC/USDT de-pegs and DEX routes |
35
+ | `get_funding_rate_arbitrage` | `funding` | $0.10 | BTC/ETH/SOL perp funding spreads (Binance, Hyperliquid, dYdX) |
36
+
37
+ ### Web3 Security & Infrastructure
38
+
39
+ | Tool | Service | Cost (USDC) | What it returns |
40
+ |---|---|---|---|
41
+ | `score_web3_wallet_intelligence` | `wallet-intel` | $0.01 | Base/ETH balance, tx history, Sybil and persona trust score |
42
+ | `get_cross_chain_gas_and_mev_oracle` | `gas` | $0.01 | Base, Arbitrum, Optimism, Solana, ETH gas and MEV risk |
43
+ | `audit_smart_contract_security` | `security` | $0.02 | Base/Solana honeypot and rug-pull scanner |
44
+ | `get_depin_gpu_compute_prices` | `compute` | $0.02 | H100, A100, RTX 4090 prices across io.net, Akash, Render |
45
+
46
+ ### AI & Web Utilities
47
+
48
+ | Tool | Service | Cost (USDC) | What it returns |
49
+ |---|---|---|---|
50
+ | `evaluate_math_or_quant_expression` | `sandbox` | $0.002 | Deterministic SymPy/NumPy math results |
51
+ | `calculate_quant_finance_model` | `sandbox` | $0.002 | Kelly Criterion, AMM slippage, compound APY, Black-Scholes |
52
+ | `extract_clean_web_markdown` | `reader` | $0.005 | Any webpage as clean, LLM-ready Markdown |
53
+ | `audit_package_dependency` | `deps` | $0.005 | CVEs via OSV.dev plus latest registry version |
54
+ | `audit_domain_trust_and_ssl` | `domain-trust` | $0.005 | RDAP domain age, TLS/SSL validity, SPF/DMARC, URLhaus phishing status |
55
+ | `parse_remote_pdf_document` | `doc-parse` | $0.01 | Page-by-page text and metadata from any public PDF URL |
56
+ | `verify_citation_or_url` | `verify` | $0.01 | URL liveness and Crossref/Wikipedia grounding |
57
+ | `check_product_price_and_stock` | `price-watch` | $0.01 | Real-time Schema.org/OpenGraph price and inventory |
58
+ | `get_llm_cost_routing_recommendations` | `llm-router` | $0.01 | Cheapest high-performing LLM per task |
59
+
60
+ ### Commodities & Travel
61
+
62
+ | Tool | Service | Cost (USDC) | What it returns |
63
+ |---|---|---|---|
64
+ | `get_global_coffee_commodities` | `coffee` | $0.01 | Arabica, Robusta, Vietnam farmgate (VND/kg) |
65
+ | `get_travel_flash_deals` | `travel` | $0.05 | Flight error fares and hotel discounts |
66
+
67
+ Every service lives at `https://<service>.rdxdata.xyz`. Call `list_rdx_catalog` first (free): it returns every endpoint, price and data-freshness note, and reports whether a payment method is configured.
68
+
69
+ ## Install
70
+
71
+ ```bash
72
+ # no install needed with uv
73
+ uvx rdx-data-mcp
74
+
75
+ # or with pip
76
+ pip install rdx-data-mcp
77
+ rdx-data-mcp
78
+ ```
79
+
80
+ Python 3.10+. Set `SKYFIRE_API_KEY`, `BUYER_PRIVATE_KEY`, or both (Skyfire is tried first). Blank values are treated as unset.
81
+
82
+ ### Claude Desktop
83
+
84
+ Edit `claude_desktop_config.json` (macOS: `~/Library/Application Support/Claude/`, Windows: `%APPDATA%\Claude\`):
85
+
86
+ ```json
87
+ {
88
+ "mcpServers": {
89
+ "rdx-data": {
90
+ "command": "uvx",
91
+ "args": ["rdx-data-mcp"],
92
+ "env": {
93
+ "SKYFIRE_API_KEY": "your_skyfire_buyer_agent_api_key",
94
+ "BUYER_PRIVATE_KEY": "",
95
+ "BASE_RPC_URL": "https://rpc.ankr.com/base"
96
+ }
97
+ }
98
+ }
99
+ }
100
+ ```
101
+
102
+ ### Claude Code
103
+
104
+ ```bash
105
+ claude mcp add rdx-data -e SKYFIRE_API_KEY=your_skyfire_buyer_agent_api_key -- uvx rdx-data-mcp
106
+ ```
107
+
108
+ ### Cursor
109
+
110
+ Add to `~/.cursor/mcp.json` (or `.cursor/mcp.json` in a project):
111
+
112
+ ```json
113
+ {
114
+ "mcpServers": {
115
+ "rdx-data": {
116
+ "command": "uvx",
117
+ "args": ["rdx-data-mcp"],
118
+ "env": {
119
+ "BUYER_PRIVATE_KEY": "0xyour_dedicated_wallet_private_key"
120
+ }
121
+ }
122
+ }
123
+ }
124
+ ```
125
+
126
+ ### Windsurf
127
+
128
+ Add to `~/.codeium/windsurf/mcp_config.json`:
129
+
130
+ ```json
131
+ {
132
+ "mcpServers": {
133
+ "rdx-data": {
134
+ "command": "uvx",
135
+ "args": ["rdx-data-mcp"],
136
+ "env": {
137
+ "SKYFIRE_API_KEY": "your_skyfire_buyer_agent_api_key"
138
+ }
139
+ }
140
+ }
141
+ }
142
+ ```
143
+
144
+ ### pip install (any client)
145
+
146
+ ```json
147
+ {
148
+ "mcpServers": {
149
+ "rdx-data": {
150
+ "command": "rdx-data-mcp",
151
+ "env": {
152
+ "SKYFIRE_API_KEY": "your_skyfire_buyer_agent_api_key"
153
+ }
154
+ }
155
+ }
156
+ }
157
+ ```
158
+
159
+ ### OpenAI Agents SDK
160
+
161
+ ```python
162
+ from agents import Agent
163
+ from agents.mcp import MCPServerStdio
164
+
165
+ async with MCPServerStdio(
166
+ params={"command": "uvx", "args": ["rdx-data-mcp"], "env": {"SKYFIRE_API_KEY": "..."}}
167
+ ) as rdx:
168
+ agent = Agent(name="Analyst", instructions="Use RDX tools for live data.", mcp_servers=[rdx])
169
+ ```
170
+
171
+ ## Pricing
172
+
173
+ Every call is priced in USDC. There is no subscription.
174
+
175
+ | Price per call | Tools |
176
+ |---|---|
177
+ | **Free** | `list_rdx_catalog` |
178
+ | $0.001 (free with Skyfire KYA) | `get_crypto_market_pulse` |
179
+ | $0.002 | `evaluate_math_or_quant_expression`, `calculate_quant_finance_model` |
180
+ | $0.005 | `extract_clean_web_markdown`, `audit_package_dependency`, `audit_domain_trust_and_ssl`, `get_global_fx_and_macro_rates`, `convert_fiat_currency_pair` |
181
+ | $0.01 | `parse_remote_pdf_document`, `verify_citation_or_url`, `check_product_price_and_stock`, `score_web3_wallet_intelligence`, `get_cross_chain_gas_and_mev_oracle`, `get_llm_cost_routing_recommendations`, `get_global_coffee_commodities` |
182
+ | $0.02 | `audit_smart_contract_security`, `get_depin_gpu_compute_prices`, `get_expired_domains_alpha` |
183
+ | $0.03 | `get_social_sentiment_velocity`, `get_web3_grants_and_airdrop_alpha` |
184
+ | $0.05 | `get_prediction_market_arbitrage`, `get_rwa_premium_analytics`, `get_dex_stablecoin_arbitrage`, `get_travel_flash_deals` |
185
+ | $0.10 | `get_funding_rate_arbitrage` |
186
+
187
+ ### Free `kya` preview tier
188
+
189
+ A Skyfire `kya` (identity-only) token costs nothing. `get_crypto_market_pulse` always uses one. Several other services also return a free preview or sample to `kya` tokens (for example FX majors on `macro-fx`, a PDF preview on `doc-parse`, a two-chain sample on `gas`). By default the server requests full paid results with a `kya-pay` token; set `RDX_SKYFIRE_TOKEN_TYPE=kya` to request previews on every call instead.
190
+
191
+ ## Funding a payment method
192
+
193
+ ### Option A: Skyfire (recommended)
194
+
195
+ 1. Create an account at [skyfire.xyz](https://skyfire.xyz) and a **Buyer agent** (docs: [docs.skyfire.xyz](https://docs.skyfire.xyz)).
196
+ 2. Fund the Buyer agent's wallet with USDC.
197
+ 3. Copy the Buyer agent API key into `SKYFIRE_API_KEY`.
198
+
199
+ The server asks Skyfire for a token sized to the call price and sends it to the RDX service in the `kyapay-token` header.
200
+
201
+ Skyfire tokens for services listed in the Skyfire Directory need the seller's service ID unless your Skyfire account belongs to an organization. Provide IDs with `RDX_SKYFIRE_SERVICE_IDS`, a JSON map keyed by sub-domain, for example `{"pulse": "<service-id>", "macro-fx": "<service-id>", "doc-parse": "<service-id>"}`. If Skyfire fails for any reason, the server falls back to x402 when `BUYER_PRIVATE_KEY` is set.
202
+
203
+ ### Option B: Base USDC wallet (x402 / AgentCash)
204
+
205
+ 1. Create a **dedicated wallet** for the agent. Never reuse a main wallet.
206
+ 2. Send it USDC on **Base mainnet** (contract `0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913`) plus a few cents of ETH on Base for gas. Most exchanges that support Base withdrawals work.
207
+ 3. Put the wallet's private key in `BUYER_PRIVATE_KEY`.
208
+
209
+ ## How payment works
210
+
211
+ 1. Skyfire first: if `SKYFIRE_API_KEY` is set, a token is created and the request is sent with `kyapay-token`.
212
+ 2. If Skyfire is not configured, or the service answers 401/402, the request is sent unauthenticated.
213
+ 3. On HTTP 402 the invoice (`asset`, `payTo`, `amount`) is decoded from the Base64 `Payment-Required` header, or from the JSON body.
214
+ 4. No `BUYER_PRIVATE_KEY`: the tool returns a structured `payment_required` result with the decoded invoice and exact setup steps.
215
+ 5. With `BUYER_PRIVATE_KEY`: an ERC-20 USDC `transfer` is sent on Base (chain id 8453), the server waits 6 seconds, then retries the identical request with `X-402-Payment-Receipt: <tx hash>`.
216
+
217
+ Every request times out after 25 seconds. Successful results include an `_rdx_payment` field showing the protocol used and, for x402, the transaction hash. If a payment is sent but the service has not accepted the receipt yet, the tool says so and an identical retry re-submits the saved receipt instead of paying again.
218
+
219
+ ## Safety
220
+
221
+ An autonomous wallet needs guard rails, so these are built in:
222
+
223
+ - Only `https://*.rdxdata.xyz` is ever called or paid.
224
+ - Only **USDC on Base mainnet** is ever sent. Testnet or other-asset invoices are refused.
225
+ - Each payment is capped at **0.25 USDC** by default (`RDX_MAX_PAYMENT_USDC`). Larger invoices are refused and nothing is paid.
226
+ - On-chain sends are serialized so concurrent calls cannot collide on the wallet nonce.
227
+ - Private keys and Skyfire keys are never logged or returned in results. Logs go to stderr.
228
+ - Tool inputs are validated before any request is made.
229
+
230
+ Use a wallet that holds only what you are willing to spend.
231
+
232
+ ## Configuration
233
+
234
+ | Variable | Default | Purpose |
235
+ |---|---|---|
236
+ | `SKYFIRE_API_KEY` | unset | Skyfire Buyer agent API key (payment rail 1) |
237
+ | `BUYER_PRIVATE_KEY` | unset | Hex private key of a Base wallet holding USDC (payment rail 2) |
238
+ | `BASE_RPC_URL` | `https://rpc.ankr.com/base` | Base mainnet RPC. `https://mainnet.base.org` is used as a fallback |
239
+ | `RDX_MAX_PAYMENT_USDC` | `0.25` | Per-call payment cap |
240
+ | `RDX_SKYFIRE_TOKEN_TYPE` | auto | Force `kya`, `pay` or `kya-pay` for every call |
241
+ | `RDX_SKYFIRE_SERVICE_IDS` | unset | JSON map of sub-domain to Skyfire seller service ID |
242
+ | `SKYFIRE_API_BASE` | `https://api.skyfire.xyz` | Skyfire API base URL |
243
+ | `RDX_ALLOW_CUSTOM_HOSTS` | unset | Set to `1` to allow non-rdxdata.xyz hosts (self-hosting, testing) |
244
+ | `RDX_LOG_LEVEL` | `WARNING` | Log level (stderr) |
245
+
246
+ ## Development
247
+
248
+ ```bash
249
+ python -m venv .venv && source .venv/bin/activate
250
+ pip install -e ".[dev]"
251
+ pytest -q
252
+
253
+ # try it interactively
254
+ npx @modelcontextprotocol/inspector rdx-data-mcp
255
+ ```
256
+
257
+ Layout:
258
+
259
+ ```
260
+ src/rdx_data_mcp/
261
+ catalog.py endpoints, prices, categories (single source of truth)
262
+ payment.py Skyfire + x402 payment client
263
+ server.py MCP server and the 26 tools
264
+ tests/ payment-flow and tool-mapping tests (no network needed)
265
+ ```
266
+
267
+ ## Publishing
268
+
269
+ ```bash
270
+ python -m build && twine check dist/* && twine upload dist/*
271
+ ```
272
+
273
+ Smithery reads `smithery.yaml` and the `Dockerfile` from the repository root. Glama.ai and mcp.so index the public repository.
274
+
275
+ ## License
276
+
277
+ MIT