FUNCTOR API

API reference · testnet

Functor API

Read market data and trade on Functor from your own code. The API follows Hyperliquid's design: one endpoint for reads, one for signed actions, and a WebSocket for updates.

Environments

NetworkHTTPWebSocketStatus
Testnethttps://api.functorfund.comwss://api.functorfund.com/wsLive. One validator, mock USDC, test FCTR. No real value.
Mainnet——Not live. Mainnet alpha is planned for Q2 2027 (roadmap).

Endpoints

Method and pathPurposeReference
POST /infoRead-only queries: markets, books, accounts, FCTR, vaultsInfo
POST /exchangeSigned actions: orders, cancels, transfers, vaultsExchange
POST /faucetTestnet only: 10,000 mock USDC and 1,000 test FCTR, once per address per 24 hoursFaucet
GET /statusNode height, state root, oracle sources, price age, deployed versionnodeStatus
GET /wsWebSocket: books, trades, account, blocksWebSocket
GET /Node name, endpoint list, deployed version

Conventions

Units

MarketIdKindTick (USD)LotMax leverage
BTC0Perpetual10.001 BTC40×
ETH1Perpetual0.10.01 ETH25×
SOL2Perpetual0.010.1 SOL20×
FCTR/USDC10000Spot0.00010.01 FCTR1×

Price in ticks = dollars ÷ tick. Size in lots = coins ÷ lot. Example: a 0.01 BTC buy at $83,300 is price: 83300, size: 10. USDC: 1 = 1,000,000 micro-USDC. FCTR: 1 = 1,000,000,000 base units. The minimum perpetuals order is $10 of notional (reduce-only orders excepted); the minimum FCTR/USDC order is 1 FCTR. The live values are in meta and spotMeta.

Quick start

Read the BTC book:

curl -s https://api.functorfund.com/info \
  -H 'content-type: application/json' \
  -d '{"type":"l2Book","coin":"BTC","nLevels":5}'

Fund a test address from the faucet:

curl -s https://api.functorfund.com/faucet \
  -H 'content-type: application/json' \
  -d '{"user":"0xYOUR_ADDRESS"}'

Sign and send an order (Node.js 18+). functor-sign.js is the reference signer the web app uses; the node is tested against it on every release.

// npm install @noble/curves@1.9.1 @noble/hashes@1.8.0
// curl -O https://functorfund.com/js/functor-sign.js
import { keccak_256 } from "@noble/hashes/sha3";
import { secp256k1 } from "@noble/curves/secp256k1";
import { makeSigner } from "./functor-sign.js";

const S = makeSigner({ keccak_256, secp256k1 });
const session = S.randomKey();            // a session key; approve it once with your wallet
const action = { type: "order", account: "0xYOUR_ADDRESS", market: 0, isBuy: true,
                 price: 83300, size: 10, tif: "Ioc", reduceOnly: false };
const res = await fetch("https://api.functorfund.com/exchange", {
  method: "POST",
  headers: { "content-type": "application/json" },
  body: JSON.stringify(S.agentRequest(session, action, Date.now())),
});
console.log(await res.json());

Versions and changes

Support

There is no official client library yet; functor-sign.js is the reference for signing. Report bugs and ask questions on Telegram. Security issues: report them privately there first, not in a public channel.

Generated from the node's source code by tools/api-docs.mjs; examples are real responses from https://api.functorfund.com. Questions: Telegram. Changes: News.

On this page

EnvironmentsEndpointsConventionsUnitsQuick startVersions and changesSupport