Skip to content

v2.0.1 — contract 2.0.1

Choose a tag to compare

@bytnode bytnode released this 16 Oct 11:33

Generated from contract 2.0.1.

  • client.ws.token() (POST /v1/ws/token): a short-lived WebSocket token (60 seconds, one connection) to open the stream without handing your API key to a web page.
  • TypeScript stream: the API key never goes into a URL any more. New token option — a function returning a fresh token, typically from your backend — called before every connection and reconnection; the key is then not sent at all. Without the ws package (browser, Deno, Bun) and without token, the stream asks POST /v1/ws/token for a token instead of putting the key in ?api_key=. With ws (Node), the key stays in the X-API-KEY header.
  • The API now refuses plain http:// (403 https_required) instead of redirecting: the SDKs always use https://, nothing to change on your side.

Install:

pip install https://github.com/bytnode/bytnode-SDK/releases/download/v2.0.1/bytnode-2.0.1-py3-none-any.whl
npm install https://github.com/bytnode/bytnode-SDK/releases/download/v2.0.1/bytnode-2.0.1.tgz