@conduit/client is a thin, typed TypeScript and JavaScript client for the Conduit API. It is read-only and has no runtime dependencies: it uses the global fetch (Node 18+ or browsers). It targets the same response envelope and the same stable error codes as the HTTP API, so what you learn from the REST surface carries over directly.
The SDK adds three things over raw fetch: typed methods for each endpoint, a ConduitError thrown on non-2xx responses, and an async iterator that auto-follows cursor pagination.
Install and build
Construct the client
Pass your API key. The base URL defaults tohttps://data.quantoraresearch.com, and the key is sent as x-api-key on every request.
The constructor accepts
apiKey, baseUrl, and fetch. On a runtime older than Node 18 with no global fetch, pass your own implementation via the fetch option or the client throws at construction.Make a call
Every typed method returns the full envelope, so you readdata and meta exactly as you would from the HTTP API.
listIndicators, listCountries, countryIndicators, resolveEntity, getObservations, getLatestObservations, getProvenance, screen, screenerFields, crossCountry, ratesAnalytics, economicCalendar, officialEvents, coverage, and sourceHealth. The low-level request(path, params) escape hatch returns the same envelope for any endpoint not yet wrapped.
Auto-paginate with the async iterator
paginate is an async generator that walks every page of a list endpoint for you, following meta.pagination.next_cursor until it is exhausted. It yields one item at a time, so you never touch a cursor.
Build screener filters
The screener takes afilter DSL of comma-separated field:operator:value clauses that are AND-ed together. buildScreenerFilter serializes structured clauses into that string so you do not assemble it by hand. The screen method accepts either form.
gt, lt, gte, lte, eq, and in. For in, pass an array; buildScreenerFilter joins it with the pipe separator the DSL expects. Discover the screenable canonical-indicator fields with conduit.screenerFields().
The screener screens public canonical-indicator values only. It never exposes any internal scoring.
Handle errors
Non-2xx responses throw aConduitError carrying the stable code, the HTTP status, the message, the requestId, and any details. This is the same error contract as the REST API.
code is one of the stable values shared with the HTTP API: bad_request, unauthorized, forbidden, not_found, rate_limited, internal_error. Branch on code, not on the human-readable message.
Related
MCP server
Native read-only tools for Claude Code, Claude Desktop, and Cursor.
llms.txt
The keyless text indexes that describe the API to an agent.