Title: get Bitcoin price using asp.net Post by: kieran5405 on May 14, 2013, 02:44:08 PM Hi, Does anyone know how to get the buying and selling bitcoin price using .NET from the mt gox or similar site . I have looked at the API sites and nothing seems to be aimed at .NET. Thanks for any pointers and help... Title: Re: get Bitcoin price using asp.net Post by: n8rwJeTt8TrrLKPa55eU on May 14, 2013, 03:52:47 PM First, use System.Net.WebClient to retrieve the content from
http://data.mtgox.com/api/2/BTCUSD/money/ticker Then, depending on how complex you wanna get, either just parse the result via Regex.Match to extract the "last" trade value, or alternatively the built-in DataContractJsonSerializer to map to a .NET class, or the built-in JsonReaderWriterFactory.CreateJsonReader will create XML from JSON, or find some free add-on libraries that will parse JSON (e.g. http://json.codeplex.com/). Title: Re: get Bitcoin price using asp.net Post by: kieran5405 on May 15, 2013, 09:25:28 AM cheers for that...got it working with ur help... |