Bitcoin Forum
May 21, 2024, 12:25:44 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Cryptsy API simple Ticker  (Read 6151 times)
Gordon Bleu (OP)
Sr. Member
****
Offline Offline

Activity: 308
Merit: 250


verified ✔


View Profile WWW
August 15, 2013, 11:27:54 AM
 #1

Need the String for a Cryptsy API get,


This URL throws all at me (i'm stupid, i know)

http://pubapi.cryptsy.com/api.php?method=marketdata

as far as i understand i could add more specific Values with &blabla=btc/anc&bla=bla

exp. http://pubapi.cryptsy.com/api.php?method=marketdata&blabla=btc/anc&bla=bla


How to create an GET Call for last sell price for Anoncoin ?



GAWMiners http://gawminers.com/ Gridseed ASICS in stock in USA
ONE YEAR FREE HOSTING AND ELECTRICITY WITH PURCHASE!






AROUSR.COM The Adult Chat Community (21+) We now accept BTCitcoins Smiley               |
Connect with hot girls for chat, talk, trade pics and more!➠Visit http://arousr.com (21+)|
luke.watson
Sr. Member
****
Offline Offline

Activity: 476
Merit: 250



View Profile
August 15, 2013, 12:21:31 PM
 #2

I found this article really helpful for getting the mtgox feed

https://coderwall.com/p/ksrula

I think you'll be able to edit it for different APIs
crypto4games
Member
**
Offline Offline

Activity: 61
Merit: 10



View Profile WWW
August 26, 2013, 04:27:09 PM
 #3

I know this was an old thread but I was playing with something similar.

I was able to set one up pretty quickly with the help from luke's post. I pasted the code below.


Code:
#!/usr/bin/env php
<?php
$c 
curl_init();
curl_setopt($cCURLOPT_RETURNTRANSFER1);
curl_setopt($cCURLOPT_HTTPHEADER, array('Accept: application/json''Content-Type: application/json'));
curl_setopt($cCURLOPT_URL'http://pubapi.cryptsy.com/api.php?method=marketdata');

$data curl_exec($c);
curl_close($c);
$obj json_decode($data);
echo 
print_r($obj->{'return'}->{'markets'}->{'ANC'}->{'lasttradeprice'}."\n"true);
?>

Buy game keys with BTC/LTC/FTC/XPM/PPC/GLD/ANC!  www.crypto4games.com @crypto4games
halibit
Legendary
*
Offline Offline

Activity: 1596
Merit: 1006



View Profile
October 15, 2013, 05:58:20 AM
 #4

I know this was an old thread but I was playing with something similar.

I was able to set one up pretty quickly with the help from luke's post. I pasted the code below.


Code:
#!/usr/bin/env php
<?php
$c 
curl_init();
curl_setopt($cCURLOPT_RETURNTRANSFER1);
curl_setopt($cCURLOPT_HTTPHEADER, array('Accept: application/json''Content-Type: application/json'));
curl_setopt($cCURLOPT_URL'http://pubapi.cryptsy.com/api.php?method=marketdata');

$data curl_exec($c);
curl_close($c);
$obj json_decode($data);
echo 
print_r($obj->{'return'}->{'markets'}->{'ANC'}->{'lasttradeprice'}."\n"true);
?>


Thanks for sharing this. That I was looking for Smiley
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!