|
Posts: 1
Registered: Feb 28, 2009
|
Posted: 2009-11-10 18:00:50
|
Any chance of a .NET API in the future?
|
|
|
Posts: 666
Registered: Sep 08, 2008
|
Posted: 2009-11-10 18:24:48
|
cvaught - no internal plans, but perhaps some motivated developer will.
|
|
|
Posts: 6
Registered: Nov 15, 2009
|
Posted: 2009-11-17 16:43:51
- Java + IKVM
Download IKVM.
Run "ikvmc.exe EchoNestAPI.jar -target:library".
Add links to needed IKVM assemblies and EchoNestAPI.dll.
Run like this:
using com.echonest.api.v3;
using com.echonest.api.v3.artist;
var artistAPI = new ArtistAPI("BQ3YSIA2D6FS7TTKC");
var artists = artistAPI.searchArtist("weezer", false);
for (int i = 0; i < artists.size(); i++)
{
var similars = artistAPI.getSimilarArtists((Artist)artists.get(i), 0, 10);
for (int j = 0; j < similars.size(); j++)
{
var asd = (Scored)similars.get(j);
var qwe = asd.getItem().ToString();
Console.WriteLine(qwe);
}
}
-
Use WCF REST Starter Kit 2 HttpClient.
It makes creating of wrapper really fast.
But server proxy should be created (second wrapper) to use in Silverlight.
-
Currently I am going to port is to use with Silverlight.
But I do not see clientaccesspolicy.xml or clientaccesspolicy.xml here and going to try Yahoo Pipes. If it not will to voodoo I will port Java version almost one to one(it seems to be easy).
-
cvaught maybe You going to port it itself?
|
|
|
Posts: 6
Registered: Nov 15, 2009
|
Posted: 2009-11-17 17:10:09
|
P.S.
Other variant of interlop (like try to run Py wrapper on IPy) or some .NET-Java bridges I consider not worse to try. But IKVM is easy and enough reliable.
WCF REST Starter Kit 2 installs "Paste XML as type" to VS2008. So not need to use xsd.exe or third party tool to generate classes for XML fast.
So until special cases (need of real commercial robust wrapper or SL/CF support) there is no reason to do .Net API.
|
|
|
Posts: 666
Registered: Sep 08, 2008
|
Posted: 2009-11-18 11:14:02
|
asdandRizzo - thanks much for this info.
|
|
|
Posts: 2
Registered: Dec 07, 2009
|
Posted: 2009-12-07 15:06:25
|
A .NET API would be really great.
If only to show that there is interest. :)
|
|
|
Posts: 13
Registered: Mar 17, 2009
|
Posted: 2009-12-07 17:10:22
|
For my music hackday project, I created a .NET wrapper for the Echo Nest API. It's not super polished or beautiful, but I can confirm that it works.
The code is on the github: Here's the exact file, EchoNest.cs, that you'll need.
In order to use it, you'll need to provide an api key (line 15), and replace references to MainForm.Trace with System.Diagnostics.Debug.WriteLine.
Keep in mind that this was written as a hack; it should do what you want, but if it doesn't, let me know, and I'll be happy to help.
|
|
|
Posts: 2
Registered: Dec 07, 2009
|
Posted: 2009-12-08 09:16:50
|
Thanks Jason, i will try your wrapper
Is there anyway to get the behind xml with the Java API? That would atleast minimize the use of java code by just importing the xml to a .NET project.
Using IKVM worked fine, but it just feels kinda wonky.
|
|
|
Posts: 666
Registered: Sep 08, 2008
|
Posted: 2009-12-14 15:52:54
|
douglasi - I'm not sure if I 100% understand you. You really don't need the Java API to get at the underlying XML. The webservices return XML that should be parseable (I presume) by a .NET project. But perhaps I'm misunderstanding you.
Paul
|
|