Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling

Re: Automatic Uploader Script

by moritz (Cardinal)
on Dec 13, 2007 at 18:40 UTC ( #656878=note: print w/replies, xml ) Need Help??

in reply to Automatic Uploader Script

divshare has an API that allows file upload. Use that.

It's documented, and you don't have to mess with web scraping and http cookies.

Replies are listed 'Best First'.
Re^2: Automatic Uploader Script
by sadarax (Sexton) on Dec 13, 2007 at 19:14 UTC
    Thanks. I did not know they had an API. Unfortunately it looks like there is no API for perl, hence my problem.

    I only know Perl and C/C++. I am not planning on learning PHP or something else just so I could write the script.

      There may be no API for perl yet, but they give detailed information about developing a new API. This should be enough for you to build the subset of the API you need (login, upload request, and an upload form). Alternatively, why not build the whole API and put it on CPAN for everyone to enjoy? The python example looked like about 200 lines of code.
      The API is language independent. It uses XML (afaict), which can be generated by any programming languages.

      It has no Perl implementation yet, but that should be easier to write than to start from WWW::Mechanize.

      So go ahead and create a good module, and upload it to CPAN ;-)

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://656878]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (4)
As of 2021-06-22 03:39 GMT
Find Nodes?
    Voting Booth?
    What does the "s" stand for in "perls"? (Whence perls)

    Results (100 votes). Check out past polls.