Sep 15

How to get your Disqus API keys

I'm working on importing my comments into the otherwise excellent Disqus commenting system, but getting ahold of your API keys can be rather difficult, so I'll just document the process here for later reference.

To call the API functions, I'm using the Java-based REST Client – which is free and very handy for this kind of thing.

  1. Log in to Disqus.com with a user that has access to the forum you want API keys for.
  2. Visit http://disqus.com/api/get_my_key/ with your browser to get the user API key (since it uses the active session to give you the API key).
  3. Call http://disqus.com/api/get_forum_list/?user_api_key=_USER_API_KEY_ to get the list of available forums, since you'll need the numeric identifier for the forum. Look through the JSON response and find the id number for the forum you want an API key for (for my blog, it's "id": "180233").
  4. Call http://disqus.com/api/get_forum_api_key/?user_api_key=_USER_API_KEY_&forum_id=180233 where 180233 is your forum id. The message field in the JSON response should contain your API key.

That's quite a bit of manual work, but it does not seem like there's currently any better method. If you happen to find one, please let me know.

  • Oct. 18, 2009

    Thank you for putting this guide together. I searched endlessly on the Disqus site for the blog API key and resorted to Google and you helped me find it!

    In my experience I don't have a REST client but using Notepad was fine for viewing those files. Manual work, but it worked. :)

    Again, thank you! :)

  • Oct. 18, 2009

    Yeah, it's very odd that this process is not documented better.

    In general, Disqus has a ways to go with their APIs if you ask me. I was trying to use it for this site, and I ended up burning a lot of hours fighting their APIs.

    There's still a lot of things you can't do – like deleting a comment. The party line is that it's nice to be able to undelete, but when you're trying to hack together an import script, the lack of ability to delete stuff and start over is just frustrating.

    In the end, I gave up and used Django threaded comments instead.

  • Nov. 17, 2009

    Thank you for posting this info. Found the Disqus keys by visiting the various URLs so I can use them in my application.

About

I am Mikkel Høgh. I have been a web developer for about 8 years. I have my own company, Reveal IT, a long with a couple of friends. We specialize in helping our customers build awesome web sites with open source tools like Drupal and Django.

Subscribe

Elsewhere

Categories

Recent Posts

Archive

BlogRoll

Popular Posts