Tengo el siguiente código :
#!usr/bin/perl
use LWP::UserAgent;
use Data::Dumper;
my $nave = LWP::UserAgent->new;
$nave->agent("Mozilla/5.0 (Windows; U; Windows NT 5.1; nl; rv:1.8.1.12) Gecko/20080201Firefox/2.0.0.12");
$nave->timeout(5);
print "\n Uploading ...\n";
my $code = $nave->post("https://post.imageshack.us/upload_api.php",Content_Type =>"form-data",Content=>
[
key=>"blabla",
fileupload=>,
format=>"json"
]
)->content;
print $code;
Y me devuelve :
Uploading ...
{"status":"1","version":8,"timestamp":1368548024,"base_url":"imageshack.us/a/","
id":1031484817,"rating":{"ratings":0,"avg":0},"files":{"server":"401","bucket":"
2281","image":{"size":460503,"content-type":"image/png","filename":"javan.png","
original_filename":"java.jpg"},"thumb":{"size":6390,"content":"image/jpeg","file
name":"javan.th.png"}},"resolution":{"width":1024,"height":768},"exif-info":{"ex
ifcompression":"Deflate/Inflate","exifimagesnum":"1"},"class":"r","visibility":"
yes","uploader":{"ip":"127.0.0.1","cookie":"b237e07ab15272ee1d9e5e38d4cadd8a","u
sername":"doddyhackman"},"links":{"image_link":"http://imageshack.us/a/img401/22
81/javan.png","image_html":"<a href='http://imageshack.us/photo/my-images/401/ja
van.png/' target='_blank'><img src='http://imageshack.us/a/img401/2281/javan.png
' alt='Free Image Hosting at http://www.ImageShack.us' border='0'/></a>'","image
_bb":"
http://image
shack.us/a/img401/2281/javan.png","image_bb2":"http://imageshack.us/
a/img401/2281/javan.png","thumb_link":"<a href='http://imageshack.us/photo/my-im ...