How do I retrieve a list of popular plugins using the WordPress.org Plugin API?

I’d like to retrieve a list of popular plugins from WordPress.org using their API.

I know I can do something like this to get a specific plugin:

http://api.wordpress.org/plugins/info/1.0/name_of_plugin

And that I can get back a list of plugins using something like this:

http://api.wordpress.org/plugins/info/1.0/?action=query_plugins

But I don’t know how to get the popular plugins. I’m guessing it is something like:

http://api.wordpress.org/plugins/info/1.0/?action=query_plugins&browse=popular

I’d like to do this without using WordPress’ (the software) Plugin API. This should be something I could type into a browser and get back the results (like one can with the above).

Thanks!

2 Answers
2

I was wrong in the earlier version of the answer and 1.1 version of the API does support this via GET request.

The basic request would be: https://api.wordpress.org/plugins/info/1.1/?action=query_plugins&request[browse]=popular

And you can add more parameters by sticking with request passed as “array” (in GET interpretation of).

See the [poor] documentation in Codex and links from there for more detail.

For in–PHP way, independent of WP core I made a WPorg Client library which implements this, among other things.

Leave a Comment