Classify ISM Manufacturing PMI releases into actionable trading scenarios. GOLDILOCKS · MODERATE · SOFT_LANDING · CONTRACTION · AMBIGUOUS
Landing page: https://473185670.github.io/macro-scenario-api/
Live API (Render, warm 24/7): https://macro-scenario-api.onrender.com
RapidAPI: https://rapidapi.com/category/Finance
| Guide | URL |
|---|---|
| Hub — All Guides | https://473185670.github.io/macro-scenario-api/macro-trading-guides.html |
| ISM PMI Trading Strategy | https://473185670.github.io/macro-scenario-api/ism-pmi-trading-strategy.html |
| Macro Trading Journal Template | https://473185670.github.io/macro-scenario-api/macro-trading-journal-template.html |
| Goldilocks Economy Trading | https://473185670.github.io/macro-scenario-api/goldilocks-economy-trading.html |
| Contraction Trading Strategy | https://473185670.github.io/macro-scenario-api/contraction-trading-strategy.html |
| Soft Landing Trade | https://473185670.github.io/macro-scenario-api/soft-landing-trade.html |
| Backtest Simulator | https://473185670.github.io/macro-scenario-api/macro-scenario-backtest.html |
- Notion Template ($12): https://4043969836017.gumroad.com/l/nztlu
- HTML Dashboard ($9.99): https://4043969836017.gumroad.com/l/pakci
- Complete Bundle ($29.99): https://4043969836017.gumroad.com/l/txmuvz
- Notion Preview: https://pale-earth-1ab.notion.site/Macro-Catalyst-Trading-Journal-3b2bf3457ff381ec85fac20dfb726a0c
Every month, the ISM Manufacturing PMI release moves markets. Traders manually read the headline, new-orders, and prices-paid numbers, then mentally bucket them into "risk-on" vs "risk-off" and decide what to do. This API automates that:
- Input: 3 numbers (headline, new_orders, prices_paid — all 0-100)
- Output: scenario classification, confidence score, sector-by-sector guidance, and a machine-readable list of trading actions.
No market-data dependencies. Pure logic. ~5ms per call.
Request body:
{
"headline": 55.6,
"new_orders": 54.2,
"prices_paid": 71.1
}Response:
{
"scenario": "GOLDILOCKS — Strong Growth, No Overheat",
"scenario_code": "GOLDILOCKS",
"bias": "RISK-ON",
"confidence": 85,
"confidence_breakdown": {"headline_strength": 40, "new_orders_strength": 30, "alignment": 15},
"equity": "BUY dip. Cyclical rotation into Industrials, Materials, Small Caps.",
"rates": "US10Y likely tests 4.80%+. Duration short.",
"crypto": "BTC benefits from risk-on. Target $66k+.",
"crdo": "Structural bid reinforced. Target $210-230.",
"actions": [
{"asset": "SPY/Equities", "direction": "BUY", "note": "...", "priority": "HIGH"},
{"asset": "US10Y", "direction": "SHORT_DURATION", "note": "...", "priority": "MEDIUM"},
{"asset": "BTC", "direction": "BUY", "note": "...", "priority": "MEDIUM"},
{"asset": "CRDO", "direction": "BUY", "note": "...", "priority": "HIGH"}
],
"inputs": {"headline": 55.6, "new_orders": 54.2, "prices_paid": 71.1},
"surprise": {"headline_surprise": 1.1, "new_orders_surprise": 1.2, "prices_paid_surprise": 15.1, "label": "BEAT"}
}Same input, returns a full Markdown report:
{"report": "# ISM Manufacturing PMI Reaction Report\n..."}{"status": "ok", "version": "1.0.0"}| Condition | Scenario | Bias | Confidence |
|---|---|---|---|
| headline ≥ 55 AND new_orders ≥ 54 | GOLDILOCKS | RISK-ON | 85% |
| headline ≥ 52 AND new_orders ≥ 50 | MODERATE | NEUTRAL-SLIGHT-RISK-ON | 70% |
| headline ≥ 50 AND new_orders < 50 | SOFT_LANDING | CAUTIOUS | 65% |
| headline < 50 | CONTRACTION | RISK-OFF | 90% |
| otherwise | AMBIGUOUS | HOLD | 40% |
Consensus: headline 54.5, new_orders 53.0, prices_paid 56.0. Surprise label: BEAT if > +0.3, MISS if < −0.3, else IN-LINE.
cd products/rapidapi_macro_scenario
pip install -r requirements.txt
# Run tests (no pytest needed)
python test_engine.py
# Start server
uvicorn main:app --reload --port 8000
# Open http://localhost:8000/docs (Swagger UI)- Push this directory to a GitHub repo (or the whole Arbitrage repo).
- Go to https://render.com → New → Web Service → connect repo.
- Render auto-detects
render.yaml. Confirm and deploy. - Your API lives at
https://macro-scenario-analysis-api.onrender.com. - Set
RAPIDAPI_PROXY_SECRETenv var (optional, for gateway auth).
Free tier: 750 hours/month, sleeps after 15min idle. Sufficient for API testing. For production, upgrade to Starter ($7/mo) — no sleep, always-on.
- Go to https://rapidapi.com → Sign in → "Add API".
- API Name:
Macro Scenario Analysis - Base URL: your Render URL (e.g.
https://macro-scenario-analysis-api.onrender.com) - Endpoints to expose:
POST /classify_scenario— "Classify ISM PMI into trading scenario"POST /ism_report— "Full ISM reaction report (Markdown)"GET /health— "Health check"
- Pricing:
- Free tier: 100 requests/month
- Pro: $0.01 per request above free tier
- Mega: $20/month for 5,000 requests
- Categories:
Finance,Data,Machine Learning - Publish. RapidAPI handles billing, rate-limiting, and key management.
Short description (≤100 chars):
Classify ISM Manufacturing PMI releases into trading scenarios with confidence scores.
Long description:
Every month, the ISM Manufacturing PMI release moves global markets. This API
classifies the release into one of five trading scenarios — GOLDILOCKS, MODERATE
EXPANSION, SOFT LANDING RISK, CONTRACTION, or AMBIGUOUS — and returns:
- Scenario code + human-readable name
- Risk bias (RISK-ON / NEUTRAL / CAUTIOUS / RISK-OFF)
- Confidence score (0-100) with breakdown
- Sector-by-sector guidance (equities, rates, crypto, AI interconnect)
- Machine-readable trading actions list (asset, direction, priority, note)
- Consensus surprise computation (BEAT / MISS / IN-LINE)
Pure logic, no external data calls — sub-10ms response. Perfect for:
- Automated trading signal generation
- Macro research dashboards
- Backtesting ISM-reaction strategies
- Embedding in Discord/Slack/Telegram trading bots
Input: three ISM indices (headline, new_orders, prices_paid), each 0-100.
Output: full scenario analysis JSON or Markdown report.
Tags: ism, pmi, macro, trading, scenario, manufacturing, finance
| File | Purpose |
|---|---|
scenario_engine.py |
Core classification logic (no deps, reusable) |
main.py |
FastAPI app with 3 endpoints |
test_engine.py |
19 unit tests (run without pytest) |
requirements.txt |
Python deps |
render.yaml |
Render.com deploy config |
README.md |
This file |
- Price: $0.01/call (free tier: 100 calls/mo)
- Marketplace: RapidAPI (3M+ developers)
- Maintenance: ~zero (pure logic, no data deps to break)
- Projected: 500 visitors/mo × 10% active × ~100 calls = ~$50/mo
Built by Macro Edge Bot — Revenue Pipeline Node 💳 SOL: DiXt5GSxLW47szTATVGyF3vsj9g8YTGBQJj4BrQUST2y