# Crypto.com Derivatives — Funding, Open Interest & Basis (`diopside/cryptocom-derivatives`) Actor

Every Crypto.com Exchange perpetual and dated future in one run: funding rate (per-interval, 8h and annualized), open interest in contracts/base/USD, mark vs index basis, bid/ask and 24h stats. Official public API — no API key, no login, no proxy.

- **URL**: https://apify.com/diopside/cryptocom-derivatives.md
- **Developed by:** [DIOPSIDE AI](https://apify.com/diopside) (community)
- **Categories:** Developer tools, Other, Agents
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.00 / 1,000 instrument records

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Crypto.com Derivatives — Funding, Open Interest & Basis

Every perpetual swap and dated future listed on the **Crypto.com Exchange**, in one run: funding rate
(per-interval, rescaled to 8h, and annualized), open interest in contracts / base units / USD, mark vs
index **basis**, best bid/ask and 24h stats. Built on Crypto.com's **official public API** — no API key,
no login, no proxy, nothing to get blocked.

Crypto.com is a top-tier venue that most crypto data actors on Apify simply skip: the CoinGlass-style
actors cover Binance/Bybit/OKX and stop there. If you run funding-rate arbitrage, basis trades, or a
cross-venue dashboard, this fills the hole — **401 instruments in ~1 minute**.

### What makes it reliable

- **Public REST endpoints only.** No key, no session, no bot protection, so there is nothing that can
  silently expire. The actor does not hold — and cannot hold — any credential that moves funds.
- **Everything is discovered at run time.** The instrument list, the contract sizes and even the
  *funding interval* are derived from live data, never hardcoded. When Crypto.com lists a new perp,
  it shows up in the next run; if the venue moves from hourly to 8-hourly funding, the derived fields
  follow automatically.
- **Partial failures are reported, never hidden.** A valuation series that fails leaves that one field
  `null`, keeps the record, and names the failure in the run's status message. Missing upstream values
  are always `null` — the actor does not crash on them.
- **Throttled and retried.** Bounded concurrency, minimum request spacing, exponential backoff on 429/5xx.

### Input

| Field | Type | Default | Description |
|---|---|---|---|
| `instrumentType` | string | `PERPETUAL_SWAP` | `PERPETUAL_SWAP`, `FUTURE`, or `both`. |
| `instrumentNames` | array | `[]` | Exact symbols, e.g. `["BTCUSD-PERP", "BTCUSD-261225"]`. Empty = every instrument of the selected type. Overrides the filters below. |
| `minVolumeUsd24h` | integer | `0` | Drop instruments that traded less than this in 24h. Crypto.com lists many near-zero-volume perps; `1000000` keeps the liquid ones. |
| `maxInstruments` | integer | `0` | Keep only the N most liquid instruments after filtering (0 = no limit). |
| `fundingHistoryCount` | integer | `0` | Attach the last N funding payments per perpetual as `funding_history`. Funding is hourly, so `24` ≈ one day. |

```json
{ "instrumentType": "both", "minVolumeUsd24h": 1000000, "fundingHistoryCount": 24 }
```

### Output

One record per instrument:

```json
{
  "instrument_name": "BTCUSD-PERP",
  "instrument_type": "PERPETUAL_SWAP",
  "display_name": "BTCUSD Perpetual",
  "base_currency": "BTC",
  "quote_currency": "USD",
  "underlying_index": "BTCUSD-INDEX",
  "contract_size": 1.0,
  "max_leverage": 100.0,
  "tradable": true,
  "expiry_time": null,
  "days_to_expiry": null,
  "last_price": 81252.7,
  "bid_price": 81253.1,
  "ask_price": 81253.2,
  "mark_price": 81253.8,
  "index_price": 81246.05,
  "high_24h": 81934.6,
  "low_24h": 80821.2,
  "price_change_24h_pct": 0.12,
  "volume_24h_base": 3094.9361,
  "volume_24h_usd": 251721650.85,
  "open_interest_contracts": 6181.928,
  "open_interest_base": 6181.928,
  "open_interest_usd": 502305141.33,
  "funding_rate": 0.000017331,
  "funding_interval_hours": 1.0,
  "funding_rate_8h": 0.000138648,
  "funding_rate_apr_pct": 15.181956,
  "funding_rate_time": "2026-09-19T20:00:00Z",
  "next_funding_time": "2026-09-19T21:00:00Z",
  "estimated_funding_rate": 0.00001684,
  "estimated_funding_rate_apr_pct": 14.75184,
  "basis": 7.75,
  "basis_pct": 0.0095389,
  "annualized_basis_pct": null,
  "ticker_time": "2026-09-19T20:44:20.335Z",
  "scraped_at": "2026-09-19T20:44:21.247Z"
}
```

Notes on the derived fields:

- **Funding rates are fractions, not percentages.** `0.000017331` = 0.0017331% per hour.
- `funding_rate_8h` rescales the venue's hourly rate to the 8-hour window Binance/Bybit/OKX quote, so
  you can compare venues without doing the arithmetic yourself.
- `funding_rate_apr_pct` and `estimated_funding_rate_apr_pct` annualize the current rate — what you'd
  pay/earn over a year *if the rate held*.
- `basis_pct` = (mark − index) / index × 100. For dated futures, `annualized_basis_pct` scales that to
  a yearly carry yield using `days_to_expiry`; it is `null` for perpetuals, which never expire.
- `funding_rate*` fields are `null` for dated futures, which pay no funding.

### Typical run sizes

| Input | Records | Time |
|---|---|---|
| `{"instrumentNames": ["BTCUSD-PERP", "ETHUSD-PERP"]}` | 2 | ~3 s |
| `{"minVolumeUsd24h": 1000000}` (liquid perps) | ~10 | ~5 s |
| `{"instrumentType": "PERPETUAL_SWAP"}` (all perps) | ~389 | ~50 s |
| `{"instrumentType": "both"}` (perps + futures) | ~401 | ~55 s |

### Use cases

- **Funding-rate arbitrage** — compare Crypto.com's `funding_rate_8h` against other venues and hold the
  cheap side. Crypto.com pays hourly, so the carry profile differs from 8-hourly venues.
- **Basis / cash-and-carry** — `annualized_basis_pct` ranks the dated BTC and ETH futures curve directly.
- **Positioning dashboards** — `open_interest_usd` across 389 perps, snapshotted on a schedule, gives you
  OI build-ups and unwinds per asset.
- **Risk monitoring** — mark vs index divergence, bid/ask spread and `max_leverage` per instrument.
- **Research datasets** — schedule the actor hourly with `fundingHistoryCount` to accumulate a complete
  funding history with no gaps.

### Pricing

Pay per event: **$0.001 per instrument record** plus the standard Apify actor start event. A full
snapshot of every perpetual and future costs about $0.40; the liquid subset costs under a cent.

### Data source & limits

Crypto.com Exchange public REST API (`/exchange/v1/public/get-instruments`, `get-tickers`,
`get-valuations`). Public market data only — no accounts, no personal data, no order placement. Values
are snapshots at run time; Crypto.com's own rate limits apply, and the actor stays well inside them.

# Actor input Schema

## `instrumentType` (type: `string`):

Perpetual swaps (funding rates), dated futures (basis + days to expiry), or both. Ignored when you list instruments explicitly.

## `instrumentNames` (type: `array`):

Exact Crypto.com symbols, e.g. BTCUSD-PERP, ETHUSD-PERP, BTCUSD-261225. Leave empty for every instrument of the selected type.

## `minVolumeUsd24h` (type: `integer`):

Skip instruments that traded less than this in the last 24 hours. Use it to drop illiquid listings. Ignored when you list instruments explicitly.

## `maxInstruments` (type: `integer`):

Keep only the N most liquid instruments after filtering (0 = no limit).

## `fundingHistoryCount` (type: `integer`):

Attach the last N funding payments to each perpetual record as a funding\_history array (0 = current rate only). Crypto.com pays funding hourly, so 24 ≈ one day.

## Actor input object example

```json
{
  "instrumentType": "PERPETUAL_SWAP",
  "instrumentNames": [
    "BTCUSD-PERP",
    "ETHUSD-PERP",
    "SOLUSD-PERP"
  ],
  "minVolumeUsd24h": 1000000,
  "maxInstruments": 0,
  "fundingHistoryCount": 0
}
```

# Actor output Schema

## `instruments` (type: `string`):

All derivative records as JSON. Append ?format=csv for CSV.

## `datasetUrl` (type: `string`):

The default dataset containing the instrument records.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "instrumentNames": [
        "BTCUSD-PERP",
        "ETHUSD-PERP",
        "SOLUSD-PERP"
    ],
    "minVolumeUsd24h": 1000000
};

// Run the Actor and wait for it to finish
const run = await client.actor("diopside/cryptocom-derivatives").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "instrumentNames": [
        "BTCUSD-PERP",
        "ETHUSD-PERP",
        "SOLUSD-PERP",
    ],
    "minVolumeUsd24h": 1000000,
}

# Run the Actor and wait for it to finish
run = client.actor("diopside/cryptocom-derivatives").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "instrumentNames": [
    "BTCUSD-PERP",
    "ETHUSD-PERP",
    "SOLUSD-PERP"
  ],
  "minVolumeUsd24h": 1000000
}' |
apify call diopside/cryptocom-derivatives --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,diopside/cryptocom-derivatives"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/8sGyPyv85j7MhLyaU/builds/K5J7CcYEFFdA52huB/openapi.json
