Developer's Guide - Api

Overview

Exchange BDCASH provides a simple and powerful REST API to allow you to programatically perform nearly all actions you can from our web interface. All requests use the application/json content type and go over https. The base url is https://exchangebdcash.com/api/{version}/. All requests are GET requests and all responses come in a default response object with the result in the result field. Always check the success flag to ensure that your API call succeeded.

We are currently restricting orders to 500 open orders and 200,000 orders a day. We reserve the right to change these settings as we tune the system.

If you have any questions, feedback or recommendation for API support you can post a question in our support center.

Getting Started



General
API Reference
Client Libraries

General

We provide a simple RESTful API. All calls are GETs and should be called via https. We will support n-1 versions of the API. Our current stable API is v1. The endpoints have a standard format as follows:

https://exchangebdcash.com/api/{version}/{method}?param=value

API Reference

Our APIs are broken into distinct groups

Public - Public information available without an API key
Market - For programatic trading of crypto currencies


Public Api

/public/getmarkets
Used to get the open and available trading markets at OpenTrade along with other meta data.
Parameters
None
Request:
https://exchangebdcash.com/api/v1/public/getmarkets
Response:
    {
	"success" : true,
	"message" : "",
	"result" : [{
			"MarketCurrency" : "DOGE",
			"BaseCurrency" : "BDCASH",
			"MarketCurrencyLong" : "Dogecoin",
			"BaseCurrencyLong" : "BigdataCash",
			"MinTradeSize" : "0",
			"MarketName" : "BDCASH-DOGE",
			"IsActive" : true,
			"Created" : "2014-02-13T00:00:00"
		}, {
			"MarketCurrency" : "DOGE",
			"BaseCurrency" : "BDCASH",
			"MarketCurrencyLong" : "Dogecoin",
			"BaseCurrencyLong" : "BigdataCash",
			"MinTradeSize" : "0",
			"MarketName" : "BDCASH-DOGE",
			"IsActive" : true,
			"Created" : "2014-02-13T00:00:00"
		}
        ]
    }

                    
/public/getorderbook
Used to get retrieve the orderbook for a given market
Parameters
parameter required description
market required a string literal for the market (ex: BDCASH-DOGE)
type optional buy, sell or both to identify the type of orderbook to return. By default type='both'
Request:
https://exchangebdcash.com/api/v1/public/getorderbook?market=BDCASH-DOGE&type=both 
Response:
    {
	"success" : true,
	"message" : "",
	"result" : {
		"buy" : [{
				"Quantity" : 12.37000000,
				"Rate" : 0.02525000
			}
		],
		"sell" : [{
				"Quantity" : 32.55412402,
				"Rate" : 0.02540000
			}, {
				"Quantity" : 60.00000000,
				"Rate" : 0.02550000
			}, {
				"Quantity" : 60.00000000,
				"Rate" : 0.02575000
			}, {
				"Quantity" : 84.00000000,
				"Rate" : 0.02600000
			}
		]
	}
    }

                    

/public/getlastmarketdata
Used to get the last summary of all coins
Request:
https://exchangebdcash.com/api/v1/public/getlastmarketdata
Response:
{
"success":true,
"message":"",
"result":{
    "coins":[
    {"id":1,"name":"BigdataCash","ticker":"BDCASH","icon":"https%3A//exchangebdcash.com/BDCASH8.png","info":{"active":true,"minconf":3,"hold":0.002,"page":"1","withdraw":"Enabled","orders":"Enabled"},"volume":0,"price":0,"fromBuyerToSeller":0,"buysell":"buy","prev_price":0,"prev_frombuyertoseller":0,"prev_buysell":"buy"},
    {"id":2,"name":"Bitcoin","ticker":"BTC","icon":"https%3A//raw.githubusercontent.com/bitcoin/bitcoin/master/src/qt/res/icons/bitcoin.png","info":{"active":true,"minconf":3,"hold":0.0002,"page":"https://bitcointalk.org/index.php?topic=5.0","withdraw":"Enabled","orders":"Enabled"},"volume":"0.000014000000","price":"1441881.0","fromBuyerToSeller":"20.186334","buysell":"buy","prev_price":"1437854.0","prev_frombuyertoseller":1437854,"prev_buysell":"buy"},
    {"id":3,"name":"Dogecoin","ticker":"DOGE","icon":"https%3A//raw.githubusercontent.com/dogecoin/dogecoin/master/src/qt/res/icons/bitcoin.png","info":{"minconf":3,"hold":2,"active":true,"page":"https://bitcointalk.org/index.php?topic=361813.0"},"volume":"8.8580000","price":"0.71999990","fromBuyerToSeller":"6.3777591","buysell":"sell","prev_price":"0.71999990","prev_frombuyertoseller":0.7199999034455098,"prev_buysell":"sell"},
    ***]
    }
}                    
                    
/public/getmarketsummary
Used to get the last 24 hour summary of one active exchange
Parameters
parameter required description
market required a string literal for the market (ex: BDCASH-DOGE)
period optional period in hours. Can be: 24, 250, 1000 or 6000. By default period=24
Request:
https://exchangebdcash.com/api/v1/public/getmarketsummary?market=BDCASH-DOGE&period=250
Response:
    {
	"success" : true,
	"message" : "",
	"result" : {
			"MarketName" : "BDCASH-DOGE",
			"High" : 0.01350000,
			"Low" : 0.01200000,
			"Volume" : 3833.97619253,
			"Last" : 0.01349998,
			"Bid" : 0.01271001,
			"Ask" : 0.01291100,
			"OpenBuyOrders" : 45,
			"OpenSellOrders" : 45
		}
    }
                    
/public/getmarkets24

Used to get the last 24 hour summary of all active exchanges

Parameters Request:
https://exchangebdcash.com/api/v1/public/getmarkets24
Response:
    {
    "success":true,
    "message":"",
    "result":{
        "TotalMarkets":22,
        "v24":30545.55264574,
        "data":{
            "YTN":{"MarketName":"BDCASH-DOGE","High":"1.10000000","Low":"1.10000000","Volume":"21.74889000","Last":"1.1000000","Bid":"1.10000000","Ask":"1.99990000","OpenBuyOrders":5,"OpenSellOrders":15,"coin_icon_src":"https%3A//raw.githubusercontent.com/conan-equal-newone/yenten/master/src/qt/res/icons/bitcoin.png","coin_info":{"minconf":6,"hold":0.002,"active":true,"page":"https://bitcointalk.org/index.php?topic=2329470.0"}},
            "WAVI":{"MarketName":"BDCASH-TKM","High":"1.01000000","Low":"0.49999999","Volume":"890.04802700","Last":"1.0100000","Bid":"0.31000001","Ask":"1.01000000","OpenBuyOrders":8,"OpenSellOrders":104,"coin_icon_src":"https%3A//raw.githubusercontent.com/wavidev-the-man/wavi/master/src/qt/res/icons/bitcoin.png","coin_info":{"minconf":3,"hold":0.002,"active":true,"page":"https://bitcointalk.org/index.php?topic=3146751.0"}},
            ...
            }
        }
    }
                    
/public/getmarkethistory
Used to retrieve the latest trades that have occured for a specific market.
Parameters
parameter required description
market required a string literal for the market (ex: BDCASH-DOGE)
Request:
https://exchangebdcash.com/api/v1/public/getmarkethistory?market=BDCASH-DOGE
Response:
    {
	"success" : true,
	"message" : "",
	"result" : [{
			"Id" : 319435,
			"TimeStamp" : "2018-01-01T03:21:20.08",
			"Quantity" : 0.30802438,
			"Price" : 0.01263400,
			"Total" : 0.00389158,
			"FillType" : "FILL",
			"OrderType" : "BUY"
		}, {
			"Id" : 319433,
			"TimeStamp" : "2018-01-01T03:21:20.08",
			"Quantity" : 0.31820814,
			"Price" : 0.01262800,
			"Total" : 0.00401833,
			"FillType" : "FILL",
			"OrderType" : "BUY"
		}, {
			"Id" : 319379,
			"TimeStamp" : "2018-01-01T02:58:48.127",
			"Quantity" : 49.64643541,
			"Price" : 0.01263200,
			"Total" : 0.62713377,
			"FillType" : "FILL",
			"OrderType" : "SELL"
		}, {
			"Id" : 319378,
			"TimeStamp" : "2018-01-01T02:58:46.27",
			"Quantity" : 0.35356459,
			"Price" : 0.01263200,
			"Total" : 0.00446622,
			"FillType" : "FILL",
			"OrderType" : "SELL"
		}
	]
    }