Skip to content
All library documents

Modeling Dated Crypto Futures Contract Specifications

Article NautilusTrader

Summary

This reference explains the fields used to represent a dated cryptocurrency futures instrument in a trading system. It covers instrument identity, underlying and quote currencies, settlement currency, inverse status, activation and expiry timestamps, price and size precision, increments, contract multiplier, lot size, optional order and notional limits, margin rates, and event timestamps. It also notes that prices may be zero or negative for some contracts, while inverse futures are an exception.

Settlement currencies distinguish common contract styles: linear contracts typically settle in the quote currency, inverse contracts in the underlying, and quanto contracts in a third currency. The reference contrasts expiring futures with perpetual contracts and provides Rust and Python construction examples plus representative exchange and data adapters. This is a data-modeling guide rather than a trading method. The conventions described are typical rather than universal, and the instrument metadata must be matched to the relevant venue and contract; the document presents no empirical strategy or performance evidence.

Key ideas

  • A dated crypto future tracks an underlying asset and expires at a specified time.
  • Contract metadata includes precision, increments, multiplier, optional trading limits, and margin rates.
  • Linear, inverse, and quanto contracts differ in their settlement currency conventions.
  • Inverse status affects sizing and costing, and inverse futures restrict prices from being zero or negative.
  • A perpetual contract should be represented separately because it has no expiration.

Tags

Full text
# Crypto Future


# Crypto Future

`CryptoFuture` represents a dated crypto futures contract. It tracks a crypto
underlying, quotes in a quote currency, settles in a settlement currency, and expires at
a fixed timestamp.

Examples include dated BTC or ETH futures on crypto derivatives venues.

## Fields

| Field                 | Rust type          | Python type        | Required/default | Notes                                    |
| --------------------- | ------------------ | ------------------ | ---------------- | ---------------------------------------- |
| `instrument_id`       | `InstrumentId`     | `InstrumentId`     | Required         | Stored as `id` in Rust.                  |
| `raw_symbol`          | `Symbol`           | `Symbol`           | Required         | Native venue symbol.                     |
| `underlying`          | `Currency`         | `Currency`         | Required         | Crypto asset the contract tracks.        |
| `quote_currency`      | `Currency`         | `Currency`         | Required         | Currency used to quote the price.        |
| `settlement_currency` | `Currency`         | `Currency`         | Required         | Currency used to settle PnL and fees.    |
| `is_inverse`          | `bool`             | `bool`             | Required         | True when sizing/costing is inverse.     |
| `activation_ns`       | `UnixNanos`        | `int`              | Required         | Contract activation timestamp.           |
| `expiration_ns`       | `UnixNanos`        | `int`              | Required         | Contract expiration timestamp.           |
| `price_precision`     | `u8`               | `int`              | Required         | Decimal places allowed for prices.       |
| `size_precision`      | `u8`               | `int`              | Required         | Decimal places allowed for order sizes.  |
| `price_increment`     | `Price`            | `Price`            | Required         | Smallest valid price step.               |
| `size_increment`      | `Quantity`         | `Quantity`         | Required         | Smallest valid size step.                |
| `multiplier`          | `Quantity`         | `Quantity`         | `1`              | Contract multiplier.                     |
| `lot_size`            | `Quantity`         | `Quantity`         | `1`              | Rounded lot or board size.               |
| `max_quantity`        | `Option<Quantity>` | `Quantity \| None` | `None`           | Maximum order quantity.                  |
| `min_quantity`        | `Option<Quantity>` | `Quantity \| None` | `None`           | Minimum order quantity.                  |
| `max_notional`        | `Option<Money>`    | `Money \| None`    | `None`           | Maximum order notional value.            |
| `min_notional`        | `Option<Money>`    | `Money \| None`    | `None`           | Minimum order notional value.            |
| `max_price`           | `Option<Price>`    | `Price \| None`    | `None`           | Maximum valid quote or order price.      |
| `min_price`           | `Option<Price>`    | `Price \| None`    | `None`           | Minimum valid quote or order price.      |
| `margin_init`         | `Option<Decimal>`  | `Decimal \| None`  | `0`              | Initial margin rate.                     |
| `margin_maint`        | `Option<Decimal>`  | `Decimal \| None`  | `0`              | Maintenance margin rate.                 |
| `tick_scheme`         | `Option<Ustr>`     | `str \| None`      | `None`           | Registered variable tick scheme name.    |
| `info`                | `Option<Params>`   | `dict \| None`     | `None`           | Adapter metadata.                        |
| `ts_event`            | `UnixNanos`        | `int`              | Required         | Event timestamp in nanoseconds.          |
| `ts_init`             | `UnixNanos`        | `int`              | Required         | Initialization timestamp in nanoseconds. |

*Note: Python constructors use `instrument_id`; Rust stores the same value as `id`.*

## Behavior

- `CryptoFuture` has asset class `Cryptocurrency` and instrument class `Future`.
- Prices can be zero or negative, except for inverse futures.
- Use `CryptoPerpetual` for crypto derivatives with no expiration.

The currency set determines the settlement style:

- **Linear**: typically sets `is_inverse=False` and settles in the quote currency.
- **Inverse**: sets `is_inverse=True` and typically settles in the underlying currency.
- **Quanto**: settles in a third currency that differs from both underlying and quote.

## Example

```rust tab="Rust"
use jiff::Timestamp;
use nautilus_core::UnixNanos;
use nautilus_model::{
    identifiers::{InstrumentId, Symbol},
    instruments::CryptoFuture,
    types::{Currency, Money, Price, Quantity},
};

let activation: Timestamp = "2024-01-08T00:00:00Z".parse().unwrap();
let expiration: Timestamp = "2024-03-29T00:00:00Z".parse().unwrap();

let btcusdt_future = CryptoFuture::builder()
    .instrument_id(InstrumentId::from("BTCUSDT-240329.BINANCE"))
    .raw_symbol(Symbol::from("BTCUSDT-240329"))
    .underlying(Currency::from("BTC"))
    .quote_currency(Currency::from("USDT"))
    .settlement_currency(Currency::from("USDT"))
    .is_inverse(false)
    .activation_ns(UnixNanos::from(activation))
    .expiration_ns(UnixNanos::from(expiration))
    .price_precision(2)
    .size_precision(6)
    .price_increment(Price::from("0.01"))
    .size_increment(Quantity::from("0.000001"))
    .max_quantity(Quantity::from("9000.0"))
    .min_quantity(Quantity::from("0.000001"))
    .min_notional(Money::from("10.00 USDT"))
    .max_price(Price::from("1000000.00"))
    .min_price(Price::from("0.01"))
    .ts_event(UnixNanos::default())
    .ts_init(UnixNanos::default())
    .build()
    .unwrap();
```

```python tab="Python"
import pandas as pd

from nautilus_trader.model import CryptoFuture
from nautilus_trader.model import Currency
from nautilus_trader.model import InstrumentId
from nautilus_trader.model import Money
from nautilus_trader.model import Price
from nautilus_trader.model import Quantity
from nautilus_trader.model import Symbol

BTC = Currency.from_str("BTC")
USDT = Currency.from_str("USDT")

btcusdt_future = CryptoFuture(
    instrument_id=InstrumentId.from_str("BTCUSDT-240329.BINANCE"),
    raw_symbol=Symbol("BTCUSDT-240329"),
    underlying=BTC,
    quote_currency=USDT,
    settlement_currency=USDT,
    is_inverse=False,
    activation_ns=pd.Timestamp("2024-01-08", tz="UTC").value,
    expiration_ns=pd.Timestamp("2024-03-29", tz="UTC").value,
    price_precision=2,
    size_precision=6,
    price_increment=Price.from_str("0.01"),
    size_increment=Quantity.from_str("0.000001"),
    max_quantity=Quantity.from_str("9000"),
    min_quantity=Quantity.from_str("0.000001"),
    min_notional=Money(10.00, USDT),
    max_price=Price.from_str("1000000.00"),
    min_price=Price.from_str("0.01"),
    ts_event=0,
    ts_init=0,
)
```

## Adapters

Representative adapters that create or consume `CryptoFuture` instruments include:

- [Bybit](../../integrations/bybit.md) for crypto futures markets.
- [Deribit](../../integrations/deribit.md) for dated crypto futures.
- [OKX](../../integrations/okx.md) for dated crypto futures.
- [Tardis](../../integrations/tardis.md) for crypto futures metadata.

## Related guides

- [Crypto Perpetual](crypto_perpetual.md) covers perpetual crypto futures.
- [Futures Contract](futures_contract.md) covers non-crypto futures contracts.

Shown in full with attribution under the source's licence. Licence: LGPL-3.0

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.