Public API


jayp1985
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 1
#50

Is the a way to only access the LastPrice Field in th request e.g. (https://www.cryptopia.co.nz/api/GetMarket/ZAP_BTC?Data=LastPrice) ?



Posted: 1/6/2018 3:30:58 PM
revelationcoin
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 4
#51

12 hours now waiting for my RDD Coin deposit ??  looks like this company has some majoy PROBLEMS !! so sorry I got involved here 



Posted: 1/7/2018 1:29:10 PM
Loghrab
Gender: Male
Country: Algeria
Threads: 0, Posts: 1
#52

"Last Volume" column is not available on GetMarket(s) any more. Is this intended?

 

 

>>>

Definition:

GetMarket
Returns market data for the specified trade pair
Param: market (Required) (TradePairId or MarketName)
Param: hours (optional, default: 24)
{
    "Success":true,
    "Message":null,
    "Data":{
                "TradePairId":100,
                "Label":"LTC/BTC",
                "AskPrice":0.00006000,
                "BidPrice":0.02000000,
                "Low":0.00006000,
                "High":0.00006000,
                "Volume":1000.05639978,
                "LastPrice":0.00006000,
                "LastVolume":499.99640000,  // this one  is missing
                "BuyVolume":67003436.37658233,
                "SellVolume":67003436.37658233,
                "Change":-400.00000000,
"Open": 0.00000500,
"Close": 0.00000600,
"BaseVolume": 3.58675866,
"BaseBuyVolume": 11.25364758,
"BaseSellVolume": 3456.06746543 } }
Actual call returns:

{
"Success":true,
"Message":null,
"Data":
{
"TradePairId":5050,
"Label":"ATMS/BTC",
"AskPrice":0.00000900,
"BidPrice":0.00000858,
"Low":0.00000746,
"High":0.00000900,
"Volume":1675543.32950911,
"LastPrice":0.00000895,
"Last volume used to be here",
"BuyVolume":1332192.40605295,
"SellVolume":856744.61136379,
"Change":-16.65,
"Open":0.00000746,
"Close":0.00000895,
"BaseVolume":13.96177440,
"BuyBaseVolume":6.60509900,
"SellBaseVolume":1663.71259156
},"Error":null}

 

Benzoate2000: 5/6/2017 3:41:25 AM

 



Posted: 1/11/2018 9:11:45 PM
vinicouto
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 1
#53

From:
https://www.cryptopia.co.nz/api/GetMarket/ZEC_BTC

I get AskPrice and BidPrice. 

Is there a way to get the AskAmount and BidAmount?

Similar to askQty and bidQty from Binance:

https://api.binance.com/api/v1/ticker/24hr?symbol=ZECBTC



Posted: 1/11/2018 11:54:33 PM
robert2411
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 1
#54

2 mistakes that i found today

for the getMarkets api

BaseSellVolume should be SellBaseVolume
and
BaseBuyVolume should BuyBaseVolume
 


Posted: 1/13/2018 10:31:17 PM
wingunt
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 1
#55

Hello, today I have this error:

"The server committed a protocol violation. Section=ResponseHeader Detail=CR must be followed by LF".

Why it appears?



Posted: 1/14/2018 7:23:46 AM
kurjak
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 1
#56

It seems that if GetMarketHistory API cuts result if there's more then 1000 orders for specified period.

Eg. I was traying to retrieve 24h history for a currency pair that has many orders and I get only 1000 which was amount of orders for the last hour only.

Is there a way to get more then 1000 orders?

Thanks!



Posted: 1/14/2018 1:27:37 PM
Patrick_Godin
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 1
#57

Can anyone help trouble shoot this error 

Details: "The server committed a protocol violation. Section=ResponseHeader Detail=CR must be followed by LF"

i am trying to import the GetMarket API into excel via get and transform "from web"

thank you



Posted: 1/14/2018 10:10:49 PM
dan_voges
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 1
#58

Is GetMarketHistory limited to 1000 results? Can I get more than 1000?



Posted: 1/15/2018 5:57:48 AM
fireball88
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 1
#59

hello everyone,

would someone be so nice and could tell me a service like "status = orderStatus(id)"? i need to see if my order is executed or not, because only if my buy-order is executed, i would like to place a sell-order?

thanks!

Sebastian



Posted: 1/15/2018 12:17:26 PM
paniczklos
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 1
#60

Hi guys,

is it just me or the API is terribly slow ? I'm getting an avarage of 1.5 second to get info on specific pair. But sometimes it's ~10 seconds.



Posted: 1/17/2018 8:52:49 PM
issamxml
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 2
#61

thanks



Posted: 1/19/2018 8:19:59 PM Edited: 1/19/2018 8:31:48 PM
wilsonglasser
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 1
#62

We need CORS for any domain and return for OPTIONS header!



Posted: 1/20/2018 3:16:16 AM Edited: 1/20/2018 3:36:48 AM
wolf_reitsamer
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 1
#63

Hi,

can anybody explain the the following parameters to me?
(Result of a call to GetMarket on ETN/BTC pair)

"Volume":86946000.41546910,
"BuyVolume":73699475.92619470,
"SellVolume":57530351.10420557,

"BaseVolume": 1049.04260274,
"BaseBuyVolume": 224.56056735,
"BaseSellVolume": 29083580879.43240820

Shouldn't "Volume" be the sum of "BuyVolume" and "SellVolume"?
And what a weird number is that in "BaseSellVolume"? (looks like it's not in the base currency (BTC) but something in ETN?)

I thought the "regular" volume parameters are all the target currency (ETN in this case) and the "base" volume parameters are in the base currency (BTC in this case)?



Posted: 1/20/2018 5:47:08 PM
Ph0t0n
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 3
#64

Hi, quick question...

 

I'm confused though... If you use GetCurrencies, GetTradePairs, or GetMarkets there are a lot of tokens/coins that aren't represented. For example: there's no IOTA, EOS, ZRX, and a lot of others.  Is there something special we need to do in order to fetch all the pairs instead of just a subset of them?

Thanks for your help!



Posted: 1/24/2018 5:57:05 AM
Hulash
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 2
#65

Hi, quick question...

 

I'm confused though... If you use GetCurrencies, GetTradePairs, or GetMarkets there are a lot of tokens/coins that aren't represented. For example: there's no IOTA, EOS, ZRX, and a lot of others.  Is there something special we need to do in order to fetch all the pairs instead of just a subset of them?

Thanks for your help!

Ph0t0n: 1/24/2018 5:57:05 AM

 

 

They don't have those markets so I'm not sure why they would have data for them? Came here looking for the same answer as the others on the excel "The server committed a protocol violation. Section=ResponseHeader Detail=CR must be followed by LF" error , surely there's someone in the community who can shed some light on it?



Posted: 1/25/2018 9:52:53 AM
Emerling
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 1
#66

Public API


 

GetCurrencies
Returns all currency data
{
    "Success":true,
    "Message":null,
    "Data":[
            {
                "Id":1,
                "Name":"Bitcoin",
                "Symbol":"BTC",
                "Algorithm":"sha256"
"WithdrawFee":0.00010000,
"MinWithdraw":0.00040000,
"MinBaseTrade":0.0,
"IsTipEnabled":false,
"MinTip":0.0,
"DepositConfirmations":6,
"Status":"Maintenance",
"StatusMessage":"Unable to sync network",
"ListingStatus": "Active" }, { ... } ] }

 

GetTradePairs
Returns all trade pair data
{
    "Success":true,
    "Message":null,
    "Data":[{
                "Id":104,
                "Label":"LTC/BTC",
                "Currency":"Litecoin",
                "Symbol":"LTC",
                "BaseCurrency":"Bitcoin",
                "BaseSymbol":"BTC",
                "Status":"OK",
                "StatusMessage":"",
                "TradeFee":"0.20000000",
                "MinimumTrade":"0.00000001,
                "MaximumTrade":"1000000000.00000000",
                "MinimumBaseTrade":"0.00000500",
                "MaximumBaseTrade":"1000000000.00000000",
                "MinimumPrice":"0.00000001",
                "MaximumPrice":"1000000000.00000000" }, { ... }] }

 

GetMarkets
Returns all market data
Param: baseMarket (optional, default: All)
Param: hours (optional, default: 24)
{
    "Success":true,
    "Message":null,
    "Data":[{
                "TradePairId":100,
                "Label":"LTC/BTC",
                "AskPrice":0.00006000,
                "BidPrice":0.02000000,
                "Low":0.00006000,
                "High":0.00006000,
                "Volume":1000.05639978,
                "LastPrice":0.00006000,
                "BuyVolume":34455.678,
                "SellVolume":67003436.37658233,
                "Change":-400.00000000,
  "Open": 0.00000500,
                "Close": 0.00000600,
                "BaseVolume": 3.58675866,
                "BaseBuyVolume": 11.25364758,
"BaseSellVolume": 3456.06746543 }, { ... }] }

 

GetMarket
Returns market data for the specified trade pair
Param: market (Required) (TradePairId or MarketName)
Param: hours (optional, default: 24)
{
    "Success":true,
    "Message":null,
    "Data":{
                "TradePairId":100,
                "Label":"LTC/BTC",
                "AskPrice":0.00006000,
                "BidPrice":0.02000000,
                "Low":0.00006000,
                "High":0.00006000,
                "Volume":1000.05639978,
                "LastPrice":0.00006000,
                "BuyVolume":67003436.37658233,
                "SellVolume":67003436.37658233,
                "Change":-400.00000000,
"Open": 0.00000500,
"Close": 0.00000600,
"BaseVolume": 3.58675866,
"BaseBuyVolume": 11.25364758,
"BaseSellVolume": 3456.06746543 } }

 

GetMarketHistory
Returns the market history data for the specified trade pair.
Param: market (Required) (TradePairId or MarketName)
Param: hours (optional, default: 24)
Param
{ "Success":true, "Message":null, "Data":[{ "TradePairId":100, "Label":"LTC/BTC", "Type":"Sell", "Price":0.00006000, "Amount":499.99640000, "Total":0.02999978, "Timestamp": 1418297368 }, { .... }] }

 

GetMarketOrders
Returns the open buy and sell orders for the specified trade pair.
Param: market (Required) (TradePairId or MarketName)
Param: orderCount (optional, default: 100)
{
    "Success":true,
    "Message":null,
    "Data":{
            "Buy":[{
                        "TradePairId":100,
                        "Label":"LTC/BTC",
                        "Price":0.00006000,
                        "Volume":455055.00360000,
                        "Total":27.303300
                   },
                   { 
                      ...
                   }],
            "Sell":[{
                        "TradePairId":100,
                        "Label":"LTC/BTC",
                        "Price":0.02000000,
                        "Volume":499.99640000,
                        "Total":9.999928
                    },
                    { 
                       ...
                    }],
            }
}
        



GetMarketOrderGroups
Returns the open buy and sell orders for the specified markets.
Param: markets (Required) (TradePairIds or MarketNames seperated by '-')
Param: orderCount (optional, default: 100)
{
    "Success":true,
    "Message":null,
    "Data":{[{
"TradePairId": 100,
"Market": "LTC_BTC" "Buy":[orders...], "Sell":[orders...] },
{
      "TradePairId": 101,
    "Market": "DOT_BTC"
            "Buy":[orders...],
            "Sell":[orders...],
            },
     {
      "TradePairId": 102,
    "Market": "DOGE_BTC"
            "Buy":[orders...],
                "Sell":[orders...],
             }
} }

 

sa_ddam213: 9/7/2015 5:02:01 AM

 



Posted: 1/27/2018 1:20:12 PM
Ph0t0n
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 3
#67

hello everyone,

would someone be so nice and could tell me a service like "status = orderStatus(id)"? i need to see if my order is executed or not, because only if my buy-order is executed, i would like to place a sell-order?

thanks!

Sebastian

fireball88: 1/15/2018 12:17:26 PM

This thread is for the public API... maybe there's something like that in the private api?



Posted: 1/28/2018 8:51:57 AM
Ph0t0n
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 3
#68

They don't have those markets so I'm not sure why they would have data for them? Came here looking for the same answer as the others on the excel "The server committed a protocol violation. Section=ResponseHeader Detail=CR must be followed by LF" error , surely there's someone in the community who can shed some light on it?

Hulash: 1/25/2018 9:52:53 AM

 Yeah, you're right - I was looking at the wrong exchange -- coding at 4am oops :-)   I haven't run into that protocol violation error yet, but if I do I'll report it in this thread.



Posted: 1/28/2018 8:53:41 AM
alonsofnr1
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 1
#69

Hello, is there a way to get more than 1000 records at one time? No matter what hours I put (24, 48), I still get only 1000 record for ETN_BTC. Thanks.



Posted: 2/2/2018 4:37:13 PM
kingslayerrr
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 1
#70

How about the API key to get market price for a currency?



Posted: 2/3/2018 7:32:08 PM
fsdajlkl
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 1
#71

How can I get total coins?



Posted: 2/5/2018 4:45:18 AM
satoshi_nakamoto_911
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 2
#72

i do it in browser - "https://www.cryptopia.co.nz/api/GetMarketOrders/215/5"  for BTA

 

{"Success":true,"Message":null,"Data":{"Buy":[],"Sell":[]},"Error":null}

 

error ?

 

sevenup: 2/22/2017 3:32:01 PM

You need to use the trade pair id, ie 2664 for BTA/BTC:

https://www.cryptopia.co.nz/api/GetMarketOrders/2664/5

hakan7punkt: 2/22/2017 8:14:51 PM

 Thanks!

I need MUSIC / BTC

Where i can see ID this pair?

Solved, i found 4942

Question.. only https supported to public method?

i need http like in bittrex.. Thanks

use http protocol

send:

GET /api/GetMarket/4942 HTTP/1.1
Host: cryptopia.co.nz
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; ru; rv:1.9.1) Gecko/20090624 Firefox/3.5


Receive...
<head><title>Document Moved</title></head>
<body><h1>Object Moved</h1>This document may be found <a HREF="https://www.cryptopia.co.nz/api/GetMarket/4942">here</a></body>    

 

How i can use http protocol? ( I can`t use https)..

 

 

Etar: 3/16/2017 8:13:23 AM

 

You wrote above:

Use .NET WebClient C# or C++.

I am useing C++ with .NET. and quiet good.

 



Posted: 2/7/2018 3:31:48 AM
Kessedy
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 1
#73

Hello,

Since it seems that it's not possible to obtain more than 1000 results when using GetMarketHistory method, could you then, please, add trade ID to the returned data? So it will be possible to make multiple requests during several hours and to combine all data to have a statistics for a longer period?

Thank you.



Posted: 2/7/2018 5:28:48 PM
dj_tereano
Gender: Unknown
Country: Unknown
Threads: 0, Posts: 1
#74

Hello,

How can I get candlestick data like OHLC and volume at 30 minute interval? Get market API seems quite close but I cannot specify candlestick time frame length... thanks.

chenxee: 1/4/2018 9:37:04 AM

 

Same questions here. The GetMarket() request accepts a parameter 'hours', but what I receive is obviously not OHLC for hour candles compared with the charts.

1) How is it possible to receive OHLC for a certain interval?

2) What is the actual timeframe relation for the given OHLC when using GetMarket() and 'hours' parameter?



Posted: 2/8/2018 11:21:39 AM