-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bitstamp (Bitcoin Exchange) Agent #182
Conversation
def bitstamp | ||
{ | ||
"ticker" => { | ||
'last' => Bitstamp::Ticker.last, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When you call Bitstamp::Ticker
6 times, does it make 6 web requests?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@cantino The answer seems to be "yes". This is the line and it is called from here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I made the improper assumption that the Bitstamp gem had some level of caching... I was wrong.
Welcome @MrHazel! Thanks for making this. Would you mind adding some simple RSpecs around this agent? |
Now that I know the Bitstamp gem isn't caching results from the API, I feel that this agent needs to be scrapped and reworked. This will allow me to add additional functionality that the gem provides. Let's ignore this pull request and I'll send another request when I've reworked everything. |
Okay, let me know if you have any questions! |
mrhazel hows it going? I want some BC ticket #s! :) |
@dsummersl if you get creative with the WebsiteAgent, you can pull this data from the BitcoinCharts JSON data. Here's what I do (I'm not using all the other trading data) this pulls from http://api.bitcoincharts.com/v1/weighted_prices.json they also have extended market data. Check here: http://bitcoincharts.com/about/markets-api/ |
Awesome I'll try that out - I can add that to the wiki of examples too if that seems useful... On Apr 24, 2014, at 1:56 PM, snicker notifications@github.com wrote:
|
I'd love it if one of you could add those to https://github.com/cantino/huginn/wiki/Agent-configuration-examples |
Done, thanks so much. On Apr 24, 2014, at 2:05 PM, Andrew Cantino notifications@github.com wrote:
|
Simple agent for grabbing ticker data from Bitstamp.