in reply to Creating REST API

If I understand correct, you're asking for help building the url. You can use URI. (See query_form.)

Replies are listed 'Best First'.
Re^2: Creating REST API
by vit (Friar) on Sep 09, 2010 at 20:41 UTC
    I looked at URI query_form you suggested. Does it mean that it allows me to pass all header parameters I listed in the example?

      Any reasonable agent (LWP::UserAgent or WWW::Mechanize are good choices) is going to handle the headers for you and the only thing special about them seems to be the dev token and maybe but not necesisarily the cookie. Without a spec I can't offer more but you should be able to add the dev token this way-

      my $mech = WWW::Mechanize->new(); ... $mech->add_header(Authorization => "YOUR DEV KEY HERE"); ...

      And you might have to also do a sign-in / authentication before doing your API calls to get an auth'd session cookie, but maybe not. Then you robustly and easily build API calls with URI or a subclass of it.