Skip to content

Installation

Describes @stxapp/stx-typescript 0.12.1, the current release.

npm install @stxapp/stx-typescript

Requires Node 18 or newer (or Bun). API-key signing uses Node’s crypto module, so run the client on a server, not in a browser.

import { STX } from "@stxapp/stx-typescript";

CommonJS works too:

const { STX } = require("@stxapp/stx-typescript");
node -e 'import("@stxapp/stx-typescript").then((m) => console.log(m.VERSION))'

The examples in this guide are ES modules that use top-level await. Save one as quickstart.mjs and run it with Node:

node quickstart.mjs

To use .js files instead, add "type": "module" to your package.json (npm pkg set type=module). For TypeScript, name the file quickstart.mts and run it with tsx: npx tsx quickstart.mts.

Pin an exact version in production. Before 1.0.0, a minor release can change the API.

STX is operated by XV Exchange, LLC, a Designated Contract Market regulated by the U.S. Commodity Futures Trading Commission (CFTC). Contracts traded on STX are cleared by XV Clearing, LLC, a CFTC-registered Derivatives Clearing Organization. Trading involves substantial risk of loss and may not be appropriate for everyone. Members risk losing the cost to enter any transaction, including fees. Consider whether trading is appropriate for you in light of your experience and financial resources. Nothing on this site is investment advice or a recommendation to trade. Past performance is not indicative of future results.

© 2026 STX. All rights reserved.llms.txtllms-full.txtView as Markdown
Docs version v1.10.5