Cogmap is pleased to introduce the first significant changes to the Cogmap APIs since their introduction.
These changes incorporate our new URL schemes and also support application authentication.
Here is the low-down:
Organization Chart Data is accessible as an XOXO document by calling a URL formatted as http://www.cogmap.com/xoxo/<CHART NAME>
This returns a nested set of unordered lists that describes the organization. Each listed item also contains several pieces of metadata associated with the list. The format is:
<li><a href=”profile.php?id=<personID>”> <FirstName> <LastName> </a> <dl> <dt>Title</dt> <dd><TitleValue></dd> <dt>CogID</dt> <dd><personID></dd> </dl>
- personID: the ID in Cogmap’s database
- FirstName: Person’s first name
- LastName: Person’s last name
- TitleValue: Person’s title
- The title of the document is the chart’s name.
So here is an awesome example: XOXO No Inc Chart!
There are a number of other interesting things you can do:
- If you weren’t sure, for some reason, how Cogmap has changed the name of a company into the URL schema that Cogmap uses, you can tell it to guess by setting the interpret flag. This might look like: http://www.cogmap.com/xoxo/no inc?interpret=1 and it will take a shot. If it fails, or if, in general, Cogmap doesn’t recognize what you are looking for, a 404 is returned.
- All of Cogmap’s APIs, and for that matter, all of the pages that are protected by access control, can now be accessed programmatically. On every member’s user settings page there is an “API Key”. Using your user name and API key will allow you to access protected pages programmatically by adding the following to your “GET” query string:
- apikey=<api key>
All of these APIs still work:
- Every profile page is actually an hCard. Munch it, crunch it, consume it.
- You can download vCards easy too. http://www.cogmap.com/vcard.php?id=<ID of Profile>