James (unknownj) wrote in lj_dev,
James
unknownj
lj_dev

In an attempt to potentially share ideas, as opposed to blowing my own trumpet (as if), I thought I'd share a few details about the "client" that I've written, which basically functions as a multi-user community management.. thing...

It's basically a bot (anonybot, plugged into a third party site, plugged into a load of custom S2 gadgets..

Authentication is a rather convoluted process that I've probably been through here before - suffice it to say, on the third party site, user get cookies that contain their username on LJ, and permissions can be set on a per-user basis. Cookies are set by challenging the user to post a comment with a specific hash on an entry (also stored in a cookie), which then has a web bug that feeds that information back to the site. The site then grabs the cookie, looks up which user posted that hash, and then authenticates that user on the site. Terribly convoluted, as I said, but it works. In addition to that, the next iteration of the site (and the previous one, actually - just not the current one) will allow users to set up passwords so they don't have to keep bouncing back to LJ to authenticate every time their cookie expires.

When authenticated, users can set their own custom names to display against their comments (typically their actual real life name), as well as optionally setting up my site to follow them on Twitter and reflect their latest tweet as a custom status line / user title against each comment (statuses can also be manually set from the main community page). Also, people get to choose a nifty little flag to display against their names, to denote their country of origin (or affiliation). It's all just done with custom style layers and associative arrays..

"Moderators" of a community are set using a central list, with different permissions available to them (well, two - delete and ban). Deletions and bans are handled by the editevent and consolecommand protocols respectively, with the commands being executed via php curl and run by anonybot, rather than under the usernames of the users in question (who aren't actually maintainers within the community). I did implement something that prevented users taking action against certain other users based on a seniority thing, but it became tedious.. Still, easily possible to do..

Accountability is ensured by having the bot also post a log entry every time somebody gets banned (like so).

Links to make use of the "ban" and "delete" features are attached variously to posts (in the case of both) and comments (in the case of ban), though unfortunately the buttons display to all users, regardless of whether they have the relevant permissions (though if clicked by the wrong person, I think I probably coded it so that they get a message telling them they can't do that..), on account of how there's no easy way to get the community style to identify which user is viewing at any given time..

And finally, submission of anonymous questions is achieved through typing into a textbox on the main community page, which then pings the text to my website, where it's checked and authorised (or rejected) by somebody with the appropriate permissions (currently a function of how active they are in the community rather than a fixed list), at which point it enters a queue to then be posted back to the community by anonybot. And nobody need know who posted it.

I have a feeling there's a bunch of other stuff (writing of current active user list, stats, "anonymous" replies by anonybot through use of the e-mail reply functionality), but that's the main guts of it.. Just thought I'd mention it in case somebody else out there is doing anything similar....
Tags: *announce, client, client: promote
Subscribe

  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 1 comment