You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
TypeScript SDK ExchangeOptions missing apiToken and getCredentials() does not forward it — Metaculus programmatic authentication broken #1384
The TypeScript SDK ExchangeOptions interface has no apiToken field, and the base Exchange.getCredentials() never includes apiToken in the credentials object sent to the sidecar. The core MetaculusExchange authenticates exclusively via apiToken; without it the sidecar always constructs Metaculus in unauthenticated mode, silently ignoring any rate-limited or private endpoints.
apiToken is absent. The Metaculus class at line 3360 has no getCredentials() override. Users of new Metaculus({ /* ... */ }) have no way to pass an API token; the credential payload sent to the sidecar will never contain apiToken, so the sidecar always builds MetaculusExchange without a token.
Python SDK
sdks/python/pmxt/client.py:329,371 — base Exchange.__init__ accepts api_token: Optional[str] and stores it.
sdks/python/pmxt/client.py:555–564 — base _get_credentials_dict() includes:
sdks/typescript/pmxt/client.ts:3360–3364 — Metaculus class, no getCredentials() override
sdks/python/pmxt/client.py:329,564 — Python correctly stores and forwards api_token
Impact
TypeScript SDK users authenticating to Metaculus must rely solely on the METACULUS_API_TOKEN environment variable set on the sidecar process. Programmatic credential passing (e.g., multi-tenant apps rotating tokens, testing pipelines, hosted mode) is impossible. There is no compile-time or runtime error; the token is silently absent from every sidecar request.
Found by automated Core-to-SDK surface coverage audit
Closing as duplicate of #469. Same underlying finding (TypeScript ExchangeOptions missing apiToken, breaking Metaculus auth). Relevant additional detail (getCredentials() forwarding gap, exchange-factory.ts evidence) has been copied over to #469.
Activity
realfishsam commentedon Jun 30, 2026
Closing as duplicate of #469. Same underlying finding (TypeScript
ExchangeOptionsmissingapiToken, breaking Metaculus auth). Relevant additional detail (getCredentials() forwarding gap, exchange-factory.ts evidence) has been copied over to #469.Generated by Claude Code
Exchange.__init__hasapi_tokenparameter not present in TypeScriptExchangeOptions#469