* neal rauhauser <nrauhau...@gmail.com> [100115 21:42]:
>   I've been working with Net::Twitter, specifically the Lists API, and I've
> run right into a brick wall. I've called add_list_member with every mix of
> name, id, slug, etc I could try, and I keep getting a "Not found" as a
> response. The userid/password pair works fine for other stuff with lists,
> it's just the add statement that gives me trouble. Yes, I've tried it both
> with two and three parameters - seems like maybe documentation doesn't match
> the code? And I did use cpan and try an update. I've dropped Marc a note but
> I'd really like to get this resolved this weekend -it's probably something
> silly, but I'd be very grateful for a working snippet that uses this call.
> my $nt = Net::Twitter->new(
>    traits   => [qw/API::REST API::Search API::Lists/],
>    username => $user,
>    password => $pass
> );
> $nt->add_list_member('5653223', '71745026') ;

Neal, I answered your private email yesterday evening, then someone
pointed out your public request, here.  So, for the benefit of anyone
else who happens to land on this via a web search, you want:

    $nt->add_list_member($user, $slug, { id => $twitter_users_numeric_id });

The value for $user is the screen name of the authenticated user (the
list owner). The value for $slug is returned in the result for
$nt->create_list.  It will be the name of the list converted to lower
case with spaces, etc.  replaced by dashes.  For example, a list named
"My Private List" will have a $slug value of 'my-private-list'.


Reply via email to