about sitemap home home
Databases Data Formats Database Search Genome Browser RNA Secondary Structure Alignments Primer Design WebServices
Technology Simple Client Asynchronity
Exercise Perl client
Bielefeld University Center of Biotechnoloy Institute of Bioinformatics BiBiServ
 
Webservices - Exercise 1
The first exercise within the chapter webservices is to use a webservice without any knowledge about it.
  1. Conditions: perl and SOAP-Lite (SOAP implementation for Perl), possibly proxy settings
  2. open an editor of your choice and cut and paste the following lines
    #!/usr/bin/env perl
    use SOAP::Lite;
    
    my $usa = shift;
    my $format = shift;
    my $style = shift;
    
    print SOAP::Lite->service("http://www.ebi.ac.uk/Tools/webservices/wsdl/WSDbfetch.wsdl")
        ->on_fault(sub {print "error!\n\n"})
        ->fetchData($usa,$format,$style);
    
  3. save the file as 'WSDbfetch.pl' and make it executable ("chmod u+x WSDbfetch.pl").
  4. a sample call of this webservice should be ./WSDbfetch.pl 'embl:xxxxx' fasta raw
    (Hint: Replace xxxxx for example with one of the following accession numbers: AB003143, AB041360, AM901009, DT726325, DN161306, EF534371, EF534372.
    If you practice this exercise in a curse, please use different accession numbers, because the EBI judges more than 25 calls with the same accession number from the same IP range within a few hours as an attac. This will result in a temporary blockade of all your future webservice calls.)
  5. ...