API ReferenceMarkets & Discovery
Stateless market filter over caller-supplied market objects. Router only.
const url = 'https://data.predictefy.com/api/router/filterMarkets';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"args":[[{"marketId":"polymarket:0xabc","status":"open","volume24h":2500}],{"volume24h":{"min":1000}}]}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://data.predictefy.com/api/router/filterMarkets \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "args": [ [ { "marketId": "polymarket:0xabc", "status": "open", "volume24h": 2500 } ], { "volume24h": { "min": 1000 } } ] }'Pure stateless filter helper. The request body is { args: [markets, criteria] }; reads filters the caller-supplied array and echoes matching market objects unchanged. This is not a catalog query and does not fetch markets. Unknown criteria fields and the non-serializable function/lambda form answer 400. Router-only; non-router exchanges answer 400.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Must be router for this cross-venue operation. Market anchors must use the canonical venue:marketId form; event anchors must use the canonical venue:eventId form.
Request Bodyrequired
Section titled “Request Bodyrequired”object
Example
[ [ { "marketId": "polymarket:0xabc", "status": "open", "volume24h": 2500 } ], { "volume24h": { "min": 1000 } }]Responses
Section titled “Responses”The filtered subset of the supplied market objects.
object
object
Examplegenerated
{ "success": true, "data": [ {} ]}VALIDATION_ERROR (non-router, bad args, bad criteria)
object
object
Always present on errors; quote this id when reporting a failed request.
Present only when a venue error is attributed to a specific exchange.
Example
{ "success": false, "error": { "code": "VALIDATION_ERROR" }}UNAUTHORIZED — platform lane (READS_ENABLE_AUTH)
object
object
Always present on errors; quote this id when reporting a failed request.
Present only when a venue error is attributed to a specific exchange.
Example
{ "success": false, "error": { "code": "VALIDATION_ERROR" }}INSUFFICIENT_CREDITS — endpoint-weighted credits
object
object
Always present on errors; quote this id when reporting a failed request.
Present only when a venue error is attributed to a specific exchange.
Example
{ "success": false, "error": { "code": "VALIDATION_ERROR" }}SCOPE_MISSING — API key lacks the route's required scope (RBAC v1)
object
object
Always present on errors; quote this id when reporting a failed request.
Present only when a venue error is attributed to a specific exchange.
Example
{ "success": false, "error": { "code": "VALIDATION_ERROR" }}ROUTE_NOT_FOUND when READS_ENABLE_FILTER is off
object
object
Always present on errors; quote this id when reporting a failed request.
Present only when a venue error is attributed to a specific exchange.
Example
{ "success": false, "error": { "code": "VALIDATION_ERROR" }}RATE_LIMITED — per-key rps limit
object
object
Always present on errors; quote this id when reporting a failed request.
Present only when a venue error is attributed to a specific exchange.
Example
{ "success": false, "error": { "code": "VALIDATION_ERROR" }}Unexpected internal error. Retryable; error.requestId identifies the failure.
object
object
Always present on errors; quote this id when reporting a failed request.
Present only when a venue error is attributed to a specific exchange.
Example
{ "success": false, "error": { "code": "VALIDATION_ERROR" }}