?

Log in

No account? Create an account
Birthday Scraping - LiveJournal Client Discussions [entries|archive|friends|userinfo]
LiveJournal Client Discussions

[ userinfo | livejournal userinfo ]
[ archive | journal archive ]

Birthday Scraping [Jun. 22nd, 2004|09:31 am]
LiveJournal Client Discussions

lj_clients

[bryant]
I'm interested in getting a list of user X's friends with birthdays. The context is a web page, not a client per se. I can see a few ways to do this:

a) Get X's FOAF data, parse the friends, then get the FOAF data for each of them. Advantages: uses the bot interface, no need to log in as X. Disadvantages: lots of HTTP requests.
b) Scrape X's userinfo, parse out the friends, then scrape their userinfo. Advantages: no need to log in as X. Disadvantages: strictly inferior to method a.
c) Require X to enter her password, and use getfriends. Advantages: uses the client API, single HTTP request. Disadvantages: ew, requiring passwords.

No matter which method is used, there will be caching of data.

I am not so emotionally committed to this project that I will be offended if anyone says "gee, that project is a bad idea." Someone said "Oh, it would be neat if" and I got interested. I think if the three options above are the only possibilities, I'll probably just skip it. However, I wanted to ask before I punted.
linkReply

Comments:
[User Picture]From: marksmith
2004-06-22 04:50 am (UTC)
Option C is the best, IMHO. That's how LochJournal works, and most other clients, I believe.

However, if you are dead set on avoiding that, use option A, but be nice to the server, please. :)
(Reply) (Thread)
[User Picture]From: boggyb
2004-06-22 10:02 am (UTC)
Using foaf isn't reliable, since people could be using external foaf files or hiding some friends from them (if you create a specific friends group then only that group appears in the file).

Logging in is best, but restricts use to account owners on their own accounts - it would stop me, for example, finding out the birthdays of your friends.

Screenscraping is the only reliable method for use by anybody, but it puts a greater burden on the LJ servers. Plus, you're at the mercy of whatever skin's being used and whatever small layout changes the LJ coders come up with (e.g. the recent grouping of friends by journal type).

I'd say use getfriends, unless you need to let people run the client on other's accounts, in which foaf is probably the next best. The LJ people probably won't thank you for screenscraping.
(Reply) (Thread)