专辑封面作品API? [关闭]

                <div class="grid--cell fl1 lh-lg">
                    <div class="grid--cell fl1 lh-lg">
                        As it currently stands, this question is not a good fit for our Q&amp;A format. We expect answers to be supported by facts, references,   or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question   can be improved and possibly reopened, <a href="/help/reopen-questions">visit the help center</a> for guidance.

                    </div>
                </div>
            </div>
            <div class="grid--cell mb0 mt8">Closed <span title="2012-07-08 04:02:09Z" class="relativetime">7 years ago</span>.</div>
        </div>
    </aside>

I'm workin on a website where i show all list of hundred to thousand songs which i played recently. I need album cover pictures for songs! Is there any free Api for that? I should send HTTP request and get a responce [only picture]

"I'm writing code in AJAX"

</div>

I've done something similar a few times recently.

You can use the free last.fm API http://www.last.fm/api

You will need an API key (which you get once registered) and that key must be sent in the request.

One of the methods available from the API is called track.getInfo:

http://www.last.fm/api/show/track.getInfo

Using this method, you can send through the artist and track name parameters (both required) like so:

http://ws.audioscrobbler.com/2.0/?
    method=track.getInfo&
    api_key=b___YOUR_API_KEY___&
    artist=Cher&
    track=Believe

The response from this request will include a series of images for that track. The following is the album node from the full request):

<album position="1">
    <artist>Cher</artist>
    <title>The Very Best of Cher</title>
    <mbid>00d677bf-46f2-34a4-86ad-e922d8466943</mbid>
    <url>
        http://www.last.fm/music/Cher/The+Very+Best+of+Cher
    </url>
    <image size="small">
        http://userserve-ak.last.fm/serve/64s/41161483.png</image>
    <image size="medium">
        http://userserve-ak.last.fm/serve/126/41161483.png</image>
    <image size="large">
        http://userserve-ak.last.fm/serve/174s/41161483.png
    </image>
    <image size="extralarge">
        http://userserve-ak.last.fm/serve/300x300/41161483.png
    </image>
</album>

You can then use your JavaScript AJAX function to filter to the image nodes returned in the response. As you can see, images come in different sizes so you can select which one you which to use.

You wont get ONLY the picture back from the request, but you can easily grab it from the response.

I hope that helps.