#!/usr/bin/perl -w

use strict;
use warnings;
use Carp;

use WebService::Browshot;


my $browshot = WebService::Browshot->new(
	key	=> 'my_api_key',
	debug	=> 0, # no more debug information
);

my $instances = $browshot->instance_list();

# Check the list of free browser
print "Free browsers:\n";
foreach my $instance (@{ $instances->{free} }) {
	my $id = $instance->{id};
	print "\t#$id: ", $instance->{browser}->{name}, " ", $instance->{width}, "x", $instance->{height}, "\n";
}
