sFOX API
Sign InOpen Account
sFOX API
sFOX API
  • Introduction
    • Welcome
    • Getting Started
    • Systems & Operations
    • Rate Limits
  • REST API
    • REST Endpoints
    • Authentication
    • Rate Limits
    • Account Management
      • Get All Balances
      • Get All Currencies
      • Get All Currency Pairs
      • Get All Transactions
      • Get Fees
    • Orders
      • Order Types
      • Create Order
      • Cancel Order
      • Cancel Multiple Orders
      • Cancel All Orders
      • Amend Order
      • Get Single Order
      • Get All Open Orders
      • Get All Done Orders
      • Get All Trades
    • Request for Quote (RFQ)
    • Post-Trade Settlement (PTS)
      • Get Account Risk Metrics
      • Get All Positions
      • Get All Funding Transactions
      • Get All Funding Rates
      • Get All Risk Modes
      • Create Transfer
    • Shorting
      • Get Account Risk Metrics
      • Get All Positions
    • Transfers
      • Get All Deposit Addresses
      • Get Single Deposit Address
      • Create Deposit Address
      • Deposit From Bank Account
      • Withdraw From Account
      • Get Single Withdrawal Fee
      • Create Transfer
    • Custody (sFOX SAFE)
      • Get Whitelisted Addresses
      • Add Whitelisted Address
      • Delete Whitelisted Address
      • Get Approval Rules
      • Create Approval Rule
      • Edit Approval Rule
      • Get Approval Requests
      • Respond to Approval Request
    • Staking
      • Get Staking Currencies
      • Get All Staking Transactions
      • Create Stake
      • Cancel Stake
      • Unstake
    • Market Data
      • Get Candlesticks
      • Get Volume Analytics
      • Get Order Estimate
      • Get Order Book
    • Reporting
      • Get Orders Report
      • Get Monthly Summary
      • Get Portfolio Valuation
      • Get All Transactions
  • WebSocket API
    • Introduction
    • Connecting
    • Rate Limits
    • Authentication
    • Subscribing & Unsubscribing
    • Message Format
    • Market Data
      • Order Book
      • Trades
      • Ticker
    • Orders & Account Data
      • Orders
      • Trades
      • Balances
      • Post-Trade Settlement
  • FIX API
    • FIX Order Entry
    • FIX Market Data
    • QuickFIX Guide
  • Errors
    • Error Codes
Powered by GitBook
On this page
  • Order Types & Algorithms
  • Order Statuses
  • Order Object
  1. REST API

Orders

Create, cancel, amend, and manage orders

PreviousGet FeesNextOrder Types

Last updated 5 months ago

sFOX recommends using our to receive order and/or trade updates where you can stream real-time order and/or trade updates and will avoid rate limits.

Order Types & Algorithms

sFOX offers a wide range of order types and execution algorithms to optimize your order execution. Short descriptions are available in the page linked below. Further details can be found in the . Or contact support to speak with an expert.

Order Statuses

Orders may have any of the following statuses.

Status
Status Code
Description

Started

100

  • The order is open and active

  • Filled quantity may be >= 0

  • Filled quantity is < the order quantity

Cancel Pending

90

  • The order is in the process of being canceled but cancelation has not been confirmed

  • The order may still receive fills

Canceled

10

  • The order was successfully canceled

  • Order may have been partially filled prior to cancelation

Done

300

  • The order was completed and is no longer active

  • Filled quantity = order quantity

  • The order will not receive new fills

Order Object

Order updates received or retrieved via the sFOX APIs will include the following object per order:

Field
Type
Description

id

int

sFOX-generated order ID, assigned on order creation.

side_id

int

ID for the order side/action. Possible values: 500 (buy order), 600 (sell order).

action

string

Order side. Possible values: buy (buy order), sell (sell order)

algorithm_id

int

algorithm

string

type

string

pair

string

Pair or product in the format basequote . e.g. btcusd, ethbtc, ethusdc

quantity

number

Order size in base currency quantity.

price

number

Order limit price.

amount

number

Amount (quote currency) to spend when buying.

net_market_amount

number

amount net fees for Market (100) orders.

filled

number

Unsigned, cumulative base currency quantity filled.

vwap

number

Cumulative volume-weighted average fill price of the order.

filled_amount

number

Unsigned, cumulative quote currency amount filled.

fees

number

Unsigned, cumulative quote currency fee amount accrued to this order.

net_proceeds

number

Signed, cumulative quote currency proceeds amount net fees.

status

string

status_code

int

routing_option

string

Special order routing instructions.

routing_type

string

Order routing type.

time_in_force

string

Order time in force specified at order creation.

expires

datetime

Expiration date of the order (for time_in_force = GTD orders)

dateupdated

datetime

Date of the most recent update to this order.

date_added

datetime

Date the order was created.

client_order_id

string

User-specified ID for this order.

user_tx_id

string

Same as above.

o_action

string

Order side. Possible values: Buy (buy order), Sell (sell order)

algo_id

int

algorithm_options

string[]

Additional object specifying special order parameters.

destination

string

Order destination.

Order type / algorithm ID. Possible values: .

Order type / algorithm name. Possible values: .

Order type / algorithm name. Possible values: .

Status name. Possible values: .

Status ID. Possible values: .

Order type / algorithm ID. Possible values: .

WebSocket API
sFOX Support Center
Order Types
Order Types & Algorithms
Order Types & Algorithms
Order Types & Algorithms
Order Types & Algorithms
Order Statuses
Order Statuses