PubMed JSON API

PubMed doesn't have a JSON API, which makes the EUtils web service difficult to use in web applications.

However, Yahoo! Pipes is ideally suited to this kind of transformation. Here are some pipes that will take input parameters and return the output from EUtils as JSON:

The ESearch pipe takes three parameters: 'q' (the search term), 'n' (number of items to return), 'offset' (offset of the first item).
The EFetch pipe takes only one parameter: 'pmid'.
The ESpell pipe takes only one parameter: 'q'.

To get JSON output from each pipe, add _render=json to the parameters. To get JSONP add a _callback parameter.

Here's an example using jQuery (view source to copy it for your own use):