Log in

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

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

XML RPC question [Dec. 21st, 2005|11:24 am]
LiveJournal Client Discussions



I have been experimenting with the XML RPC interface using a perl program.  I'll let it be known up front that I am a novice at both, and so my question may be pretty stupid.  But hopefully someone can help me.

I am using as a basis a script Brad wrote http://cvs.livejournal.org/browse.cgi/livejournal/src/xmlrpc-client/

I am attempting to use/learn the getevents call.

    my $req = {
         'username' => $acct->{'username'},
         'password' => $acct->{'password'},
         'truncate' => '20',
         'selecttype' => 'day',
         'year' => '2004',
         'month' => '12',
         'day' => '29',
    my $res = $xmlrpc->call('LJ.XMLRPC.getevents', $req);
    if ($res->events) {
        print "blah\n";
        print "Event: " . $res->event;

With this I receive an error:
Can't locate object method "events" via package "XMLRPC::SOM" at ./dan.pl line 41, <C> line 1.

So I'd like to know how to properly retrieve the struct containing an array of events.  And how should I traverse them?  (example: how would I list the subject from each event on that day?)

Thanks for any help!


[User Picture]From: alexmc
2006-02-16 02:39 pm (UTC)
That is a shame. I'll have a look to see whether I can get the info I need without XMLRPC...

(Reply) (Parent) (Thread)