Cryptsy api support
This commit is contained in:
parent
9f02359c4c
commit
ee2c90525c
@ -48,6 +48,8 @@ class Tools extends Base {
|
|||||||
return 'coinchose';
|
return 'coinchose';
|
||||||
} else if (preg_match('/btc-e.com/', $url)) {
|
} else if (preg_match('/btc-e.com/', $url)) {
|
||||||
return 'btce';
|
return 'btce';
|
||||||
|
} else if (preg_match('/cryptsy.com/', $url)) {
|
||||||
|
return 'cryptsy';
|
||||||
}
|
}
|
||||||
$this->setErrorMessage("API URL unknown");
|
$this->setErrorMessage("API URL unknown");
|
||||||
return false;
|
return false;
|
||||||
@ -73,6 +75,9 @@ class Tools extends Base {
|
|||||||
case 'btce':
|
case 'btce':
|
||||||
return $aData['ticker']['last'];
|
return $aData['ticker']['last'];
|
||||||
break;
|
break;
|
||||||
|
case 'cryptsy':
|
||||||
|
return $aData['return']['markets'][$strCurrency]['lasttradeprice'];
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
// Catchall, we have no data extractor for this API url
|
// Catchall, we have no data extractor for this API url
|
||||||
$this->setErrorMessage("Undefined API to getPrice() on URL " . $this->config['price']['url']);
|
$this->setErrorMessage("Undefined API to getPrice() on URL " . $this->config['price']['url']);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user