API now works, although it still needs to be polished and fully fleshed out. It's probably pretty fragile at this stage of the game. Made some fake database functions so I could get this to work. We should just be able to swap those out of the real thing later on. We're also still lacking authentication of any kind. I think the best way to go would be to rely on token based authentication for the API and session based authentication for everything else. It shouldn't be terribly hard to integrate either of those with LDAP. Code asthetically less than perfect at the moment, I'll clean that up when I'm a bit more awake.