Install
openclaw skills install prediction-bridge-devSearch Prediction Bridge prediction-market events by text or X (Twitter) link via the backend API.
openclaw skills install prediction-bridge-devUse this skill when the user wants to find relevant prediction markets/events for:
Use this skill when the user asks:
This skill is best for:
Not a good fit when the user wants:
This skill calls the existing Prediction Bridge backend endpoint:
POST /api/v1/search/unifiedIt returns matched events (prediction market events) and optionally matched news.
API base (defaults to production):
PREDICTION_BRIDGE_API_URLDefaults:
https://prediction-bridge.onrender.com/api/v1http://localhost:8000/api/v1text unchanged. The backend will resolve it.Use exec with curl:
API_URL="${PREDICTION_BRIDGE_API_URL:-https://prediction-bridge.onrender.com/api/v1}"
curl -sS -X POST "$API_URL/search/unified" \
-H "Content-Type: application/json" \
-H "X-Request-ID: pb-$(date +%s)" \
--data-binary @- <<'JSON'
{
"text": "<USER_TEXT_OR_X_URL>",
"limit": 10,
"offset": 0,
"include_inactive": false,
"include_markets": true,
"markets_per_event": 1,
"include_translations": false
}
JSON
Notes:
markets_per_event: 1 to keep payload small but still show the leading market.markets_per_event.POST /search/unified returns JSON with this shape (fields may be omitted or null depending on data availability):
{
"source": {
"type": "x" ,
"url": "https://x.com/.../status/...",
"text": "resolved tweet text (optional)",
"id": "optional"
},
"events": [
{
"score": 0.82,
"event": {
"id": 123,
"title": "...",
"description": "...",
"source": "polymarket",
"source_url": "https://polymarket.com/event/...",
"status": "active",
"volume_usd": 12345.67,
"liquidity_usd": 2345.0,
"end_date": "2026-12-31T00:00:00Z",
"markets": [
{
"id": 999,
"question": "...",
"outcomes": ["Yes", "No"],
"outcome_prices": {"Yes": 0.61, "No": 0.39},
"volume": 1000.0,
"active": true,
"closed": false
}
]
}
}
],
"news": [
{
"score": 0.74,
"news": {
"id": 456,
"title": "...",
"summary": "...",
"url": "https://...",
"image_url": "https://...",
"source": "...",
"published_at": "2026-02-01T12:34:56Z"
}
}
]
}
Key points:
events[] is the primary output. Each item has { score, event }.score is a relevance score; higher is better.event.markets is present when you requested include_markets: true.
markets_per_event, the backend may return only a preview subset.news[] is optional supporting context; do not let it crowd out event results.Important:
events as a clean, human-readable list.events is missing or not an array, treat it as empty.events by score descending (even if the backend already sorted).event.source_url as the click-through link.event.source_url is missing, fall back to the frontend detail page:
https://www.predictionbridge.xyz/event/<event.id>event.markets[0].outcome_prices exists:
outcome_prices.Yes or outcome_prices.Longevent.source)event.source_url preferred)news exists, include at most 1–3 items with title + URL as extra context.events is empty:
After you receive JSON:
events is empty, say no matches were found and ask for a more specific query.event.source_url when present)event.markets, if present)If news is present, optionally show 1–3 related news items as context.
PREDICTION_BRIDGE_API_URL and whether the API is reachable.