BRAX Developer Info

The BRAX API is available for non-commercial use by outside developers. For the time being, you will need to be setup manually by us to access the API. Contact us in channel #bor on efnet to get setup with access to the API.

To authenticate users for your application, you'll be using the brax.auth.identify() method. The identify method requires two arguments, a username and a password.

Identifying a User

brax.auth.identify( string username, string password )

If the username and password matches, this method will return a user token string, which will be used for performing all other subsequent calls to the API that require user authentication.

Example Code

The following is an example of how to identify a user on using the Ruby XML-RPC client.

require 'xmlrpc/client'

# Instantiate client object and connect to BRAX API
# with your API username and password
@rpc_client = XMLRPC::Client.new3({

# Authenticate a user account by passing a 
# username and password.  A unique identification token is returned.
  user_token ="brax.auth.identify",BORDOM_NICK,BORDOM_PASS)
rescue XMLRPC::FaultException => e
  # Handle error e.faultString

At this point, the user_token string is then used to pass into other API methods that require user authentication.

Performing User-Level Actions

Now that we've successfully authenticated this user, we can permit them to perform user-level actions such as bumping an item to the front page:

brax.items.bumpItem( int item_id, string user_token )

For a full list of method calls (uses real-time API reflection), see API Methods.

© 2003-2014
Subscribe via Feed or Email


“ok im going to a medtronic seminar now”