GithubHelp home page GithubHelp logo

crypto-chassis / cryptochassis-data-api-docs Goto Github PK

View Code? Open in Web Editor NEW
77.0 7.0 11.0 55 KB

A REST API providing snapshot, tick, and aggregated market data for crypto-currencies

algo-trading altcoin api backtest exchange invest market-data trade trading market-depth

cryptochassis-data-api-docs's Introduction

Dear All, to reduce the cost burden on our operation and to put more focus on our library https://github.com/crypto-chassis/ccapi, starting May 26, 2023, we will stop servicing data to external users. We deeply apologize for the inconvenience. However, if you would like to quickly set up an in-house data collection pipeline, we can provide coding and consulting services for that purpose. Feel free to directly email us at [email protected] or contact us on Discord https://discord.gg/b5EKcp9s8T.

Table of Contents generated with DocToc

Public Data API From CryptoChassis

  • This REST API provides snapshot data (e.g. market depth) and tick data (e.g. trades) for crypto-instruments.
  • Supported exchanges: see the allowed values of parameter exchange for the information endpoint.
  • Backfill history: historical data since 2016-01-01, wherever applicable.
  • Institutional quality and independently verifiable.
  • To spur innovation and industry collaboration, this API is open for use by the public without cost.
  • We specialize in market data collection, high speed trading system, infrastructure optimization, and proprietary market making. Hire us as engineers, liquidity providers, traders, or asset managers.
  • Join us on Discord https://discord.gg/b5EKcp9s8T and Medium https://cryptochassis.medium.com.

General API Information

Reqeust Rate Limits

  • The limit on the API is based on public IPs: 10 requests per second per IP.

Public API Endpoints

Information

GET /information?dataType=<dataType>&exchange=<exchange>&instrument=<instrument>

Information about available data types, exchanges, instruments, and the available time range.

Parameters:

Name Mandatory Description
dataType yes Allowed values: market-depth, trade.
exchange yes Allowed values: coinbase, gemini, kraken, bitstamp, bitfinex, bitmex, binance-us, binance-usds-futures, binance-coin-futures, huobi, huobi-usdt-swap, huobi-coin-swap, okex, kucoin, deribit.
instrument no Comma seperated list.

Response:

[
  {
    "dataType": "market-depth",
    "exchange": "coinbase",
    "instrument": "btc-usd",
    "availability": {
      "depth_10": {
        "firstAvailableTime": {
          "seconds": 1594166400,
          "iso": "2020-07-08T00:00:00.000Z"
        },
        "lastAvailableTime": {
          "seconds": 1630886400,
          "iso": "2021-09-06T00:00:00.000Z"
        }
      },
      "depth_1": {
        "firstAvailableTime": {
          "seconds": 1572480000,
          "iso": "2019-10-31T00:00:00.000Z"
        },
        "lastAvailableTime": {
          "seconds": 1630886400,
          "iso": "2021-09-06T00:00:00.000Z"
        }
      }
    },
    "examples": [
      "https://api.cryptochassis.com/v1/market-depth/coinbase/btc-usd"
    ]
  },
  ...
]

Examples:

https://api.cryptochassis.com/v1/information?dataType=market-depth&exchange=coinbase

Market Depth

GET /market-depth/<exchange>/<instrument>?depth=<depth>&startTime=<startTime>

Daily 1-second snapshot data on market depth (aka order books or Level 2 data) up to a depth of 10.

Parameters:

Name Mandatory Description
exchange yes E.g. coinbase.
instrument yes E.g. btc-usd.
depth no Allowed values: 1, 10. Defaults to 1.
startTime no E.g. 1594166400 (seconds), 2020-07-08 (iso). Defaults to most recent.

Response:

{
    "urls": [
        {
            "startTime": {
                "seconds": 1594166400, // unix time
                "iso": "2020-07-08T00:00:00.000Z"
            },
            "endTime": {
                "seconds": 1594252800, // unix time
                "iso": "2020-07-09T00:00:00.000Z"
            },
            "url": "https://marketdata-e0323a9039add2978bf5b49550572c7c.s3.amazonaws.com/market_depth/bitfinex/btc_usd/1594166400.csv.gz?AWSAccessKeyId=AKIATPNB7YZIUQR3JVNF&Expires=1594515416&Signature=T25g0YP0ALalj5jCUAQ9mtZ41M0%3D"
            // daily data, gzipped csv. Url is pre-signed and could expire.
        }
    ],
    "expiration": "300 seconds"
}

Examples:

https://api.cryptochassis.com/v1/market-depth/coinbase/btc-usd

CSV file format:

time_seconds,bid_price_bid_size|...,ask_price_ask_size|... 1594512000,9234.05_2.20765974|...,9234.98_2|...

If there is a gap in "time_seconds", it means that the market depth snapshot at that moment is the same as the previous moment.

Trade

GET /trade/<exchange>/<instrument>?startTime=<startTime>

Daily trade ticks. Each tick represents a single trade.

Parameters:

Name Mandatory Description
exchange yes E.g. coinbase.
instrument yes E.g. btc-usd.
startTime no E.g. 1577318400 (seconds), 2019-12-26 (iso). Defaults to most recent.

Response:

{
    "urls": [
        {
            "startTime": {
                "seconds": 1577318400, // unix time
                "iso": "2019-12-26T00:00:00.000Z"
            },
            "endTime": {
                "seconds": 1577404800, // unix time
                "iso": "2019-12-27T00:00:00.000Z"
            },
            "url": "https://marketdata-e0323a9039add2978bf5b49550572c7c.s3.amazonaws.com/trade/coinbase/btc_usd/1577318400.csv.gzip?AWSAccessKeyId=AKIATPNB7YZIUQR3JVNF&Expires=1577486042&Signature=jQ9Vya3X9yBc7x26MyWhRKdKEdI%3D"
            // daily data, gzipped csv. Url is pre-signed and could expire.
        }
    ],
    "expiration": "300 seconds"
}

Examples:

https://api.cryptochassis.com/v1/trade/coinbase/btc-usd

CSV file format:

time_seconds,price,size,is_buyer_maker 1594512000.14,9235,0.004,0

Legacy CSV file format:

time_seconds,time_nanoseconds,price,size,is_buyer_maker,trade_id 1594512000,140000000,9235,0.004,0,96572013

Troubleshoot

cryptochassis-data-api-docs's People

Contributors

cryptochassis avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

cryptochassis-data-api-docs's Issues

More help

I believe it would be enormous help to new users to reference some worked examples in your README.md file.

I have just made my own Jupyter notebook from your post at
Conquer High Frequency Backtesting
and it was enormously helpful in demonstrating how to use this API as well as how to implement the data retrieval and display in a Pandas DF.

If you want to go the whole hog then you could include a completed notebook in this depositary.

I realize this may not be necessary for experienced developers but for mere market practitioners such as myself it would be very valuable.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.