Professor Mass (professormass) wrote in lj_dev,
Professor Mass
professormass
lj_dev

  • Mood:

editfriends XML-RPC issue.

Hi!

I'm trying to get my PHP-based XML-RPC client update friends' lists using the editfriends method, but I'm getting an odd response. Here's my PHP code:




require('Configuration/Configuration.php');
require($FunctionRoot . 'xmlrpc.php');

// LJ XML-RPC Variables
$add = array();
$add['username'] = 'user_to_be_friended';
$add['fgcolor'] = '#00688B';
XMLRPC_prepare($add,'struct');

$array = array();
$array['username'] = 'professormass';
$array['password'] = 'my_password';
$array['add'] = $add;

XMLRPC_prepare($array,'struct');

$result = XMLRPC_request('www.livejournal.com','/interface/xmlrpc','LJ.XMLRPC.editfriends', array($array));




I get this response:



Application failed during request deserialization: wrong element 'username'



Virtually the exact same code works for using the postevent method. Anybody have any clues on this one?
Tags: client, client: friends, client: xmlrpc, code: php
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