Template Web Service, version 0
This page refers to template web service, version 0. Please check here that you are really connecting to the server with web services version 0 and not 1.
This page describes the InterMine template web service and how to construct links to get the results of a particular template. With this service you can include template results in your web site or automatically generate links and download data with a script. Results can be obtained in various formats. For general information about InterMine web services see WebService.
Quick HOW TO
1.Simple template:
Example link: http://www.flymine.org/query/service/template/results?name=AllGene_Chromosome&op1=eq&value1=Drosophila+melanogaster&extra1=&format=html&start=1&size=10
In this replace !AllGene_Chromosome with name of your template (must be public), Drosophila+melanogaster replace with required organism name and eq replace with abbreviation of your operation.
If you want to get results from positions 50 to 99, replace start with 50 and size with 50.
2.Template with lookup:
Example link: http://www.flymine.org/query/service/template/results?name=Gene_allGOTerms&op1=LOOKUP&value1=CG11348&extra1=A.+aegypti&format=html
In this case operation LOOKUP means that CG11348 will be searched for in gene identifiers, gene synonyms, secondary identifiers and so on. It solves problems with gene identifier ambiquity. So replace CG11348 with your gene identifier, A.+aegypti with your organism.
Important notices
- '+' in Drosophila+melanogaster is encoded space mark. The reason for this is that some special characters in URL must be encoded.
- InterMine can generate the link for you. Go to the template page and click on 'Embed'.
Detailed parameter description
| Parameter | Value | Description |
| name | string | Template name. |
| op1 | string | URL encoded operation of constraint. Required. Following table shows permitted operations. |
| value1 | string | URL encoded value of constraint. Required. |
| extra1 | string | URL encoded extra value. Used and required when the constraint is LOOKUP. It searches for the identifier provided in the value1 parameter in all identifier fields like synonym, primary identifier, secondary identifier and restricts results to the organism specified in the extra1 parameter. |
Other parameters: start, size, tcount, format. For the description see Parameters description
If the template has more constraints there will be more parameters like op2 and value2, and all the parameters are required.
Operations
| Operation | Encoded operation | Abbreviation |
| = | %3D | eq |
| != | %21%3D | ne |
| < | %3C | lt |
| <= | %3C%3D | le |
| > | %3E | gt |
| >= | %3E%3D | ge |
Encoded operation or corresponding abbreviation can be used in URL.
Limitations
- Only links to superuser templates are now available.
- Link is not available for the case when the template uses a list constraint (object must be in a certain list).
