An example module for use with this page of bioinformatics web APIs. This one searches the PDB for the keyword $query and returns a list of results.
sub pdb{ my $query = shift; my $service = SOAP::Lite->service('http://xml.nig.ac.jp/wsdl/SRS.wsdl'); my $response = $service->searchSimple("[PDB-AllText:$query]"); my $items; while ( $response =~ m/PDB\:(\w*)/g ){ $items .= qq|<li><a href="http://pdbbeta.rcsb.org/pdb/explore.do?structureId=$1">$1</a></li>|; } my $result = qq|<ul>$items</ul>|; return $result; }