[BREAKING, read desc.] added Apps

The older way of doing stuff (with roottokens and just kind of mushing
it all together) was pretty sketch, this makes it somewhat better. I'll
be cleaning up the code (I know, I always say I will but I never do)
sometime soon. This fixes a number of bugs that could have come up.

Also added an option (by default) to add the serialized JSON to the
database, so the server doesn't have to string together a JSON item
every time it's requested