Many interaction databases now work with PSI format files. Most of the main databases can do this and the EBI has set up PSICQUIC View, a very useful page where you can query multiple databases at once.
Note that it is very important to limit the results according to the detection method. There is a lot of noise in protein interaction databases. Depending on what you want to do you could limit to only experimentally verified interactions or to only direct, binary interactions
(so exclude the results of, for example, ChIP analyses which can also find complexes) etc.
That said, here's a simple example script that will query the APID database using its PSICQUIC service:
#!/usr/bin/perl
use strict;
use warnings;
use LWP::Simple;
my @proteins;
## Read a list of target proteins, one per line (this expects UniProt names)
open(my $fh, "$ARGV[0]") or die "Need a list of proteins as the 1st argument: $!\n";
while (<$fh>) {
chomp;
push @proteins, $_;
}
close($fh);
## Get human interactions only
my $species="9606";
## Get the interactions for each target protein
foreach my $protein (@proteins) {
my $queryUrl= "http://cicblade.dep.usal.es/psicquic-ws/webservices/current/search/query/$protein";
$queryUrl .= "?taxidA:$species%20ANDtaxidB:$species";
my $tries=1;
my $content = get $queryUrl;
while ($tries<=10) {
if (defined($content)) {
$tries=11;
} else {
print STDERR "Could not retrieve $queryUrl, retrying($tries)...\n";
$content = get $queryUrl;
}
$tries++;
}
# Now list all interactions
my @lines = split(/\n/, $content);
my $LINES= @lines;
my $count = 0;
for my $line (@lines) {
$count++;
my @flds = split(/\t/, $line); # split tab delimited lines
# split fields of a PSIMITAB 2.5 line
my ($idA, $idB, $altIdA, $altIdB, $aliasA, $aliasB, $detMethod, $author, $pub, $orgA, $orgB, $intType, $sourceDb, $intID, $conf) = @flds;
## Here you can add logic to limit the interactions by specific detection method codes ($detMethod)
## or database of origin etc.
## Print
print "$line\n"
}
}
I tested it by using a file with the UniProt ID for human TP53 (P04637) and it returns a list of 3988 interactions (showing 10 randomly selected results below):
$ foo.pl names.txt | shuf -n 10
uniprotkb:Q9BWC9 uniprotkb:P04637 - - uniprotkb:CCDC106(gene_name) uniprotkb:TP53(gene_name) psi-mi:"MI:0007"(anti tag coimmunoprecipitation) Zhou, J. et al.(2010) pubmed:20159018 taxid:9606(Homo sapiens) taxid:9606(Homo sapiens) - psi-mi:"MI:0469"(intact) intact:EBI-7812926 -
uniprotkb:P04637 uniprotkb:O15126 - - uniprotkb:TP53(gene_name) uniprotkb:SCAMP1(gene_name) psi-mi:"MI:0018"(two hybrid) Lim, J. et al.(2006) pubmed:16713569 taxid:9606(Homo sapiens) taxid:9606(Homo sapiens) - psi-mi:"MI:0463"(biogrid) biogrid:720622 -
uniprotkb:P63165 uniprotkb:P04637 - - uniprotkb:SUMO1(gene_name) uniprotkb:TP53(gene_name) psi-mi:"MI:0018"(two hybrid) Minty, A. et al.(2000) pubmed:10961991 taxid:9606(Homo sapiens) taxid:9606(Homo sapiens) - psi-mi:"MI:0463"(biogrid) biogrid:262339 -
uniprotkb:P04637 uniprotkb:P31350 - - uniprotkb:TP53(gene_name) uniprotkb:RRM2(gene_name) psi-mi:"MI:0416"(fluorescence microscopy) Xue, L. et al.(2003) pubmed:12615712 taxid:9606(Homo sapiens) taxid:9606(Homo sapiens) - psi-mi:"MI:0465"(dip) dip:DIP-40167E -
uniprotkb:P04637 uniprotkb:Q00987 - - uniprotkb:TP53(gene_name) uniprotkb:MDM2(gene_name) psi-mi:"MI:0004"(affinity chromatography technology) Dai, MS. et al.(2004) pubmed:15308643 taxid:9606(Homo sapiens) taxid:9606(Homo sapiens) - psi-mi:"MI:0463"(biogrid) biogrid:478073 -
uniprotkb:Q99576 uniprotkb:P04637 - - uniprotkb:TSC22D3(gene_name) uniprotkb:TP53(gene_name) psi-mi:"MI:0428"(imaging technique) Ayroldi, E. et al.(2015) pubmed:25168242 taxid:9606(Homo sapiens) taxid:9606(Homo sapiens) - psi-mi:"MI:0463"(biogrid) biogrid:1255896 -
uniprotkb:P04637 uniprotkb:Q00987 - - uniprotkb:TP53(gene_name) uniprotkb:MDM2(gene_name) psi-mi:"MI:0415"(enzymatic study) Lui, K. et al.(2013) pubmed:23572512 taxid:9606(Homo sapiens) taxid:9606(Homo sapiens) - psi-mi:"MI:0463"(biogrid) biogrid:859223 -
uniprotkb:P25685 uniprotkb:P04637 - - uniprotkb:DNAJB1(gene_name) uniprotkb:TP53(gene_name) psi-mi:"MI:0004"(affinity chromatography technology) Qi, M. et al.(2014) pubmed:24361594 taxid:9606(Homo sapiens) taxid:9606(Homo sapiens) - psi-mi:"MI:0463"(biogrid) biogrid:938952 -
uniprotkb:P04637 uniprotkb:Q8IW41 - - uniprotkb:TP53(gene_name) uniprotkb:MAPKAPK5(gene_name) psi-mi:"MI:0424"(protein kinase assay) Sun, P. et al.(2007) pubmed:17254968 taxid:9606(Homo sapiens) taxid:9606(Homo sapiens) - psi-mi:"MI:0469"(intact) intact:EBI-1202077 -
uniprotkb:Q13526 uniprotkb:P04637 - - uniprotkb:PIN1(gene_name) uniprotkb:TP53(gene_name) psi-mi:"MI:0096"(pull down) Mantovani, F. et al.(2007) pubmed:17906639 taxid:9606(Homo sapiens) taxid:9606(Homo sapiens) - psi-mi:"MI:0469"(intact) intact:EBI-6112688 -