My favorites | Sign in
Project Home Downloads Wiki Issues Source
Search
for
API  
Lingr API documentation
Updated Feb 4, 2010 by kenn.ej...@gmail.com

Introduction

Lingr offers a full set of API so that developers can build tools that interoperate with Lingr's functionality. This document is a reference for the API.


Basics

HTTP methods

You call the Lingr API methods using simple HTTP requests. Some of the methods require that you use the GET method, while others require POST.

All of the Lingr API methods require that you pass some parameters when you make the call. For methods that use HTTP GET, you simply include the parameters in the URL that you use to access the method.

For methods that use HTTP POST, the parameters should be included in the body of the request, and the body should have a Content-Type of application/x-www-form-urlencoded.

Format

Lingr supports JSON, XML as data formats. Unless otherwise stated, all API methods supports XML and JSON as a response format, and you can specify it in a request parameter of format with xml or json. When the format parameter is omitted, XML is used by default.

When JSON is specified, all methods accepts callback parameter as well, which will pass the JSON object to a given function so that you can simply eval the response.

  • http://www.lingr.com/api/session/create?format=json&callback=myFunc

For instance, when callback=myFunc is given, the response body will look like this:

myFunc({"status": "ok", "session": "2lA42FcLddH"})

Character encoding

Lingr uses, and expects UTF-8 encoding everywhere. That's all you should know.

API keys

To use the Lingr API, you need to have an API key. We use API keys to track usage of the Lingr API, as well as to maintain compliance with the Lingr API Terms of Use.

Getting an API key is simple. Sign up for a Lingr account, Go to here, read the Lingr API Terms of Use, and click the link upon your agreement.

Error codes

The complete list of error codes is available here.


Tutorial

Here's the tutorial to have a overview of how the Lingr API works. You might want to try advanced tutorial also.


Showcase

If you are looking for API libraries or applications that use the API, go to the Showcase.

There is public code written in Ruby, PHP, .NET, Javascript.


API Methods

Session

  • session.create
  • session.verify
  • session.destroy

Authentication

  • auth.login
  • auth.logout

Explore

  • explore.getHotRooms
  • explore.getNewRooms
  • explore.getHotTags
  • explore.getAllTags
  • explore.search
  • explore.searchTags
  • explore.searchArchives

User

  • user.getInfo
  • user.startObserving
  • user.observe
  • user.stopObserving

Room

Chat

  • room.enter
  • room.getMessages
  • room.observe
  • room.setNickname
  • room.say
  • room.exit

Query

  • room.getInfo
  • room.getArchives

Management

  • room.create
  • room.changeSettings
  • room.delete

Common Structures


Notes


Other Resources


Recent Changes


Got a comment?

If you've got something to say about the API reference, please let us know in the Google Groups.


Sign in to add a comment
Powered by Google Project Hosting