Forum Replies Created

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter quenenni

    (@quenenni)

    That’s perfect.

    Thanks for your help Yorman

    NB:
    The link in the post didn’t correctly transcribed here but was correct in the mail I received and is correct in the stackoverflow post.
    (add brackets around the word ‘slug’)

    Thanks again.

    Thread Starter quenenni

    (@quenenni)

    In case someone else want to do the same, here is a easy way to achieve that (in Python):

    This example is for the plugin akismet.
    You just have to change the name at the end of the url var to match the plugin you want.

    Also, you can get different format from the server.
    You just have to change the extension (.json / .xml / .php)

    #! /usr/bin/env python
    
    from urllib2 import urlopen
    import json
    
    url = 'https://api.wordpress.org/plugins/info/1.0/akismet.json'
    response = urlopen(url).read()
    
    try:
        json_response = json.loads(response)
    
    # This to print everything
    #    print json.dumps(json_response, sort_keys=True, indent=4)
    
        print "Version: ", json_response['version']
        print "requires: ", json_response['requires']
        print "tested: ", json_response['tested']
        print "last_updated: ", json_response['last_updated']
    
    except (ValueError, KeyError, TypeError):
        print "error"

    Thread Starter quenenni

    (@quenenni)

    Yeepee.. I found the solution.
    (the problem is always to find the right words to use in the search)

    wordpress-plugin-api-latest-download
    It’s in Php, but that’s much much better than nothing.
    I’ll try to make it work with Python.

Viewing 3 replies - 1 through 3 (of 3 total)