APOD Webservice

A couple of weeks ago I created a little web service for APOD, as part of my Gadget Competition submission. What this webservice does is grab a copy of the APOD homepage, parse its contents with regular expressions, extract the image and the description, save a resized copy of the image on the local server (200px in width, the height is computed with respect to the aspect ratio) and create an XML with the data for later use.

The webservice can be called via http://clau.sparetimegroup.net/apod/apod.php. If you want to obtain the APOD for one of the previous days you can safely use the date parameter with the following date format: YYMMDD. For example, here’s what you would need to call to get the APOD for November 1st, 2007: http://clau.sparetimegroup.net/apod/apod.php?date=071101

The Gadget Competition is basically over, but this webservice will stay online indefinitely. It currently records about 200 hits daily so it’s far from any impact on this webserver’s performance.

Feel free to use it, but I may not be held responsible for any wrongdoings, use at your own risk. I’m only providing a more 21st century way of digesting the Astronomy Picture of the Day website.

Share and Enjoy:These icons link to social bookmarking sites where readers can share and discover new web pages.
  • blinkbits
  • BlinkList
  • del.icio.us
  • digg
  • Fark
  • Furl
  • Reddit
  • Spurl
  • YahooMyWeb

Leave a comment

Please be polite and on topic. Your e-mail will never be published.