This API allows to trade.

All requests to Trade API come from the following URL: https://coinsmarkets.com/apiv1.php

The method is POST.

All server responses are received in the JSON format.

Each request needs an authentication. As authentication you will need your username , password and pin.

In the case of successful request, the response will be of the following type:

{
	"success":1,
	"return":{<response>}
}

Response in the case of error:

{
	"success":0,
	"error":"<error>"
}

Gettradinginfo

Returns information about the users current balance.

Sample:

data=gettradinginfo.

Sample response:

{
	"success":1,
	"return":{
	 "open_orders":number of open trade,
         "server_time":server time ,
		"funds":{
			"doge":balnce,
			"btc":balnce,
			"ltc":balnce
                        ...

		},

	}
}

funds: Your account balance available for trading. Doesnt include funds on your open orders.

open_orders: The number of your open orders.

server_time: Server time .

Activetrade

Returns the list of your active orders.

Sample:

data=Activetrade[BTC_LTC]

Sample response:

{
	"success":1,
	"return":{
		"trade_id":{
			"pair":"btc_ltc",
			"type":"sell",
			"amount":trade amount,
			"rate":trade price,
			"timestamp_created":created time,
			"status":0
		},

	}
}
    

OrderInfo

Returns the information on particular order.

Sample:

data=OrderInfo[order_id]

Sample response:

{
	"success":1,
	"return":{
		"trade_id":{
			"pair":"btc_ltc",
			"type":"sell",
			"amount":trade amount,
			"rate":trade price,
			"timestamp_created":created time,
			"status":0
		},

	}
}
        

TradeHistory

Returns trade history for current pair.

Sample:

data=TradeHistory[pair]

Sample response:

{
	"success":1,
	"return":{
		"trade_id":{
			"pair":"btc_ltc",
			"type":"sell",
			"amount":trade amount,
			"rate":trade price,
			"timestamp_created":created time,
			"status":0
		},

	}
}


        

DepositLog

Returns deposit history for current coin.
Sample:
data=DepositLog[coin]
Sample response:
{
	"success":1,
	"return":{
		"transaction_id":{
			"coin":"btc",
			"type":"Generate/receive",
			"amount":amount,
			"txid":transaction txid,
                        "blockhash":blockhash,
			"timestamp":received time,
			"status":0
		},

	}
}

         

WithdrawlLog

Returns withdrawl history for current coin.
Sample:
data=withdrawlLog[coin]
Sample response:
{
	"success":1,
	"return":{
		"id":{
			"coin":"btc",
			"amount":amount,
			"to_address":wallet address,
			"timestamp":processing time,
			"status":0
		},

	}
}

    

Canceltrade

Cancel a trade.
Sample:
data=Canceltrade[trade_id]
Sample response:
{
	"success":1,
	"return":{
		"order_id":$pair ,
                   "funds":{
			"amount":amount,
			"price":buy/sale price,
			"timestamp":trade creation time,
			"status":0
		},

	}
}



        

Depositaddress

Get deposit address for a coin.
Sample:
data=Depositaddress[coin]
Sample response:
{
	"success":1,
	"return":{


			"coin":coin name such as BTC,
			"name":name of coin such as bitcoin,
			"address":your deposit address,
			"status":0


	}
}



    

Depositaddress

Get deposit address for a coin.
Sample:
data=Depositaddress[coin]
Sample response:
{
	"success":1,
	"return":{


			"coin":coin name such as BTC,
			"name":name of coin such as bitcoin,
			"address":your deposit address,
			"status":0


	}
}



Withdraw

Withdraw coins to your wallet.
Sample:
data=Withdraw[coin_amount_address]
Sample response:
{
	"success":1,
	"return":{


			"coin":coin name such as BTC,
			"amount":amount to withdraw,
			"address":ddress where your coin will be sent,
			"status":0


	}
}

Trade

Set a new Buy/Sale trade.
Sample:
data=Trade[btc_ltc_sale_price_amount]
Sample response:
{
	"success":1,
	"return":{


            "pair":"BTC_LTC",
            "type":sale or buy trade,
            "amount":"ammount to buy or sale",
            "price":"price",
            "status":0";


	}
}

PHP curl Samples :

This sample allow to get Activetrade BTC_LTC ;

$data = "username=username&password=password&pin=pin&data=Activetrade[BTC_LTC]";

// our curl handle (initialize if required)

$content_type=" application/json";

$ch = curl_init();

curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);

curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/4.0 (compatible; coinsmarkets PHP client; '.php_uname('s').'; PHP/'.phpversion().')');

curl_setopt($ch,CURLOPT_HEADER, false);

curl_setopt ($ch, CURLOPT_POST, 1);

curl_setopt($ch, CURLOPT_URL, 'https://coinsmarkets.com/apiv1.php');

curl_setopt($ch, CURLOPT_POSTFIELDS, $data);

// run the query

$res = curl_exec($ch);

This sample allow to get your BTC address ;

$data = "username=username&password=password&pin=pin&data=depositaddress[BTC]";

// our curl handle (initialize if required)

$content_type=" application/json";

$ch = curl_init();

curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);

curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/4.0 (compatible; coinsmarkets PHP client; '.php_uname('s').'; PHP/'.phpversion().')');

curl_setopt($ch,CURLOPT_HEADER, false);

curl_setopt ($ch, CURLOPT_POST, 1);

curl_setopt($ch, CURLOPT_URL, 'https://coinsmarkets.com/apiv1.php');

curl_setopt($ch, CURLOPT_POSTFIELDS, $data);

// run the query

$res = curl_exec($ch);

This sample allow to withdraw 1 btc to address 1uilGdtqhsmRHfvLGRKTntpjq445yNMyWB ;

$data = "username=username&password=password&pin=pin&data=withdraw[BTC_1_1uilGdtqhsmRHfvLGRKTntpjq445yNMyWB]";

// our curl handle (initialize if required)

$content_type=" application/json";

$ch = curl_init();

curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);

curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/4.0 (compatible; coinsmarkets PHP client; '.php_uname('s').'; PHP/'.phpversion().')');

curl_setopt($ch,CURLOPT_HEADER, false);

curl_setopt ($ch, CURLOPT_POST, 1);

curl_setopt($ch, CURLOPT_URL, 'https://coinsmarkets.com/apiv1.php');

curl_setopt($ch, CURLOPT_POSTFIELDS, $data);

// run the query

$res = curl_exec($ch);

This sample allow to set a trade : 10 litecoin for a price of 1000 bitcoin per LTC ;

$data = "username=username&password=password&pin=pin&data=withdraw[BTC_LTC_buy_1000_10]";

// our curl handle (initialize if required)

$content_type=" application/json";

$ch = curl_init();

curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);

curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/4.0 (compatible; coinsmarkets PHP client; '.php_uname('s').'; PHP/'.phpversion().')');

curl_setopt($ch,CURLOPT_HEADER, false);

curl_setopt ($ch, CURLOPT_POST, 1);

curl_setopt($ch, CURLOPT_URL, 'https://coinsmarkets.com/apiv1.php');

curl_setopt($ch, CURLOPT_POSTFIELDS, $data);

// run the query

$res = curl_exec($ch);

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 





News

Market Cleanup

Time : 2017-07-16
Hello
We disabled few pair to clean our exchange , please withdraw all remaining coins from those pair and cancel their trade :
Disabling pair KGC/BTC
Disabling pair CRC/BTC
Disabling pair Vgina/BTC
Disabling pair Tide/DOG
Disabling pair DEA/BTC
Disabling pair stax/BTC
Disabling pair ECO/LTC
Disabling pair Trance/BTC
Disabling pair Trance/DOG
Disabling pair Pulse/DOG
Disabling pair GMF/DOG
Disabling pair KRA/LTC
Disabling pair Blazer/DOG
Disabling pair RBC/LTC
Disabling pair Hallo/BTC
Disabling pair Putincoin/BTC
Disabling pair Creedtoken/BTC
Disabling pair bitmo/BTC
Disabling pair ARTA/BTC
Disabling pair ARTA/DOG
Disabling pair Tatto/DOG
Disabling pair Cryptogold/DOG
Disabling pair VTA/DOG
Disabling pair XVP/DOG
Disabling pair Thom/DOG
Disabling pair SPP/DOG
Wallet will remain online for one month from date of this news (16-07-2017) and then will be shut down .
Regards


AsicCoin removal

Time : 2017-07-13
After Dev request we delisted AsicCoin , please withdraw all your ASCC coins .

Issue with Durer Coin

Time : 2017-07-02
Durer Coin wallet is down , we contacted the dev already we are waiting for a fix .

Closing Wok/BTC trade pair

Time : 2017-07-01
After DEV request , we decided to close the trade pair BTC/WOK . please all members cancel your trades and withdraw your worker coins .

Stake Online

Time : 2017-06-29
Staking feature is switched on again .

Stake again disabled

Time : 2017-06-20
We have tested enhanced stake , now we are fixing all minor issues that we faced .So stake is disabled for the moment ,
All stacked coins are counted and will be credited once we switch on stake again .


Newly Listed
NameTicker
Signatum SIGT
AdCoin ACC
OliTwistCoin OLIT
Bitmxittz BMXT
AsicCoin ASCC
Atlas ATLAS
RSGPcoin RSGP
EXPAT EXPAT
700 Coin 700
BUBBLE BUB

Our advantages:

Contacts:

email Support

Log json format :

Full trade log json format