23 April 2012Introducing the Symphony Extensions API

Browsing extensions yourself is one thing, but letting Symphony itself browse extensions is another! This site now has a read-only API for retrieving developers and their extensions.


I promised this long ago and it’s finally here — I give you the Symphony Extensions API:

http://symphonyextensions.com/api/

The API is read-only (you can’t submit or update extensions), and is XML only (no JSON here, get over it). From the root endpoint you should be able to navigate the API using the <link> elements in the responses. Here’s a full breakdown:

Extensions

List extensions

http://symphonyextensions.com/api/extensions/

Returns all extensions on the site, sorted by most recent update. This URI accepts the following parameters:

  • page
  • sort (updated, name or popularity)
  • order (asc or desc)
  • type (e.g. security or workflow)
  • keywords (e.g. search caching)
  • compatible-with (e.g. 2.3 returns only extensions compatible with Symphony 2.3)

This XML output shows the basic information about each extension and its developer. The extension’s latest release is shown:

<version rel="latest" released="2012-04-04">0.3</version>

And if you are searching using the compatible-with parameter, the release compatible with that version is also returned:

<version rel="compatibility" with="2.3.0">0.3</version>

Extension detail

http://symphonyextensions.com/api/extensions/:id/

Returns all known information about an extension including its README, release history and compatibility. The compatibility matrix is calculated by parsing the <releases> element, using the presence and absence of @min, @max attributes found in the extension.meta.xml file.

Extension types

http://symphonyextensions.com/api/extensions/types/

Returns a list of all known extension types.

Developers

List developers

http://symphonyextensions.com/api/developers/

Returns all developers who have released one or more extension on the site.

Developer detail

http://symphonyextensions.com/api/developers/:username/

Returns all known information about a developer, plus lists their extensions.

Why?

This opens up the possibility for clever things:

  • Symphony can detect a new compatible release of an extension that works with your Symphony version
  • When upgrading Symphony, it can tell you which extensions have yet to be updated, so you can choose to delay
  • It was a fun challenge.