Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/genepi/imputationserver i…
Browse files Browse the repository at this point in the history
…nto release

# Conflicts:
#	docs/api.md
  • Loading branch information
abought committed Apr 27, 2023
2 parents dd84c6e + dffa414 commit 42ea3d8
Show file tree
Hide file tree
Showing 39 changed files with 60 additions and 1,120 deletions.
68 changes: 11 additions & 57 deletions docs/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,80 +12,34 @@ _**Note:** the tokens from Michigan Imputation Server and TOPMed Imputation Serv
## Job Submission
The API allows setting several imputation parameters.

### Michigan Imputation Server Job Submission

URL: https://imputationserver.sph.umich.edu/api/v2
POST /jobs/submit/minimac4

The following parameters can be set:

| Parameter | Values | Default Value | Required |
| ------------- |:-------------| :-----|---|
| files | /path/to/file | | **x** |
| mode | `qconly`<br> `phasing` <br> `imputation` | `imputation` | |
| password | user-defined password | auto generated and send by mail | |
| files-source | `file-upload`<br> `sftp`<br> `http` | `file-upload` | |
| refpanel | `apps@hapmap-2`<br> `apps@hrc-r1.1`<br> `apps@1000g-phase-1`<br> `apps@1000g-phase-3-v5` <br> `apps@genome-asia-panel@1.0.0` <br> `apps@cappa` | - | **x** |
| phasing | `eagle`<br> `no_phasing` | `eagle` | |
| population | `eur`<br> `afr`<br> `asn`<br> `amr`<br> `sas`<br> `eas`<br> `AA`<br> `mixed` | - | **x** |
| build | `hg19`<br> `hg38` | `hg19` | |
| r2Filter | `0` <br> `0.001` <br> `0.1` <br> `0.2` <br> `0.3` | `0` | |

### TOPMed Imputation Server Job Submission

URL: https://imputation.biodatacatalyst.nhlbi.nih.gov/api/v2
POST /jobs/submit/imputationserver@1.2.7
POST /jobs/submit/imputationserver@1.7.3

The following parameters can be set:

| Parameter | Values | Default Value |
| ------------- |:-------------| :-----|
| input-files | /path/to/file | |
| input-mode | qconly, imputation | imputation |
| input-password | user-defined password | auto |
| input-files-source | file-upload, sftp, http | default: file-upload |
| input-refpanel | apps@topmed-r2@1.0.0 | - |
| input-phasing | eagle | eagle |
| input-population | all, mixed | all |
| Parameter | Values | Default Value | Required |
| ----------- |:--------------------------------------------------| :-----|---|
| job-name | (user specified) | | |
| files | /path/to/file | | **x** |
| mode | `qconly`<br> `phasing` <br> `imputation` | `imputation` | |
| refpanel | `apps@topmed-r2@1.0.0` | - | **x** |
| phasing | `eagle`<br> `no_phasing` | `eagle` | |
| build | `hg19`<br> `hg38` | `hg19` | |
| r2Filter | `0` <br> `0.001` <br> `0.1` <br> `0.2` <br> `0.3` | `0` | |


### Examples

### Examples: curl

#### Submit a single file

To submit a job please change `/path-to/file.vcf.gz` to a valid vcf file and update `TOKEN` with your API Token:


Command:

```sh
TOKEN="YOUR-API-TOKEN";

curl https://imputationserver.sph.umich.edu/api/v2/jobs/submit/minimac4 \
-H "X-Auth-Token: $TOKEN" \
-F "files=@/path-to/file.vcf.gz" \
-F "refpanel=apps@1000g-phase-3-v5" \
-F "population=eur"
```

Response:

```json
{
"id":"job-20160504-161420",
"message":"Your job was successfully added to the job queue.",
"success":true
}
```

#### Submit a single file using TOPMed

To submit a job please change `/path-to-file` to the actual path.

```sh
curl -H "X-Auth-Token: <your-API-token>" -F "input-files=@/path-to-file" -F "input-refpanel=apps@topmed-r2@1.0.0" -F "input-phasing=eagle" https://imputation.biodatacatalyst.nhlbi.nih.gov/api/v2/jobs/submit/imputationserver@1.2.7
curl -H "X-Auth-Token: <your-API-token>" -F "input-files=@/path-to-file" -F "input-refpanel=apps@topmed-r2@1.0.0" -F "input-phasing=eagle" https://imputation.biodatacatalyst.nhlbi.nih.gov/api/v2/jobs/submit/imputationserver@1.7.3
```

#### Submit multiple files using 1000 Genomes Phase 3
Expand Down
26 changes: 3 additions & 23 deletions docs/getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,12 +41,7 @@ The Michigan Imputation Server has several additional reference panels available

More details about all available reference panels can be found [here](/reference-panels/).

### Input files

VCF files can be uploaded either from your local disk or by specifying a remote sftp / HTTPS location. In both cases, several files or several locations can be selected at once. Please make sure that all files fulfill the [requirements](/prepare-your-data).


#### Upload VCF files from your computer
### Upload VCF files from your computer

When using the file upload, data is uploaded from your local file system to Michigan Imputation Server. By clicking on **Select Files** an open dialog appears where you can select your VCF files:

Expand All @@ -57,26 +52,11 @@ After you have confirmed your choice, all selected files are listed in the submi

![](images/upload-data02.png)


#### Import VCF files via SFTP

An other convenient way to use your data is by importing it directly from a remote SSH server. This can be achieved by selecting **Secure File Transfer Protocol (SFTP)**.

After clicking on the **Import Files** button, a new dialog appears where you can enter your SFTP credentials and the URLs of your files or folders. A URL consists of the server address followed by the full Unix path. A path can be either point to a folder or to a file. Several paths can be specified in consecutive lines.

![](images/upload-data03.png)
Please make sure that all files fulfill the [requirements](/prepare-your-data).


!!! important
Be sure that your SFTP server is **not in a private network** and you are able to establish a connection from outside.

#### Import VCF files via HTTPS

Data can also be imported by using HTTP(S) link. This can be achieved by selecting **URLs (HTTP)**.

After clicking on the **Add URLs** button, a new dialog appears where you can add the links.

![](images/upload-data04.png)
Since version 1.7.2 URL-based uploads (sftp and http) are no longer supported. Please use direct file uploads instead.

### Build
Please select the build of your data. Currently the options **hg19** and **hg38** are supported. Michigan Imputation Server automatically updates the genome positions (liftOver) of your data. All reference panels except TOPMed are based on hg19 coordinates.
Expand Down
Binary file removed docs/images/upload-data03.png
Binary file not shown.
Binary file removed docs/images/upload-data04.png
Binary file not shown.
2 changes: 1 addition & 1 deletion files/imputationserver-beagle.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
id: imputationserver-beagle
name: Genotype Imputation supporting Beagle (Minimac4)
description: This is the new Michigan Imputation Server Pipeline using <a href="https://github.com/statgen/Minimac4">Minimac4</a>. Documentation can be found <a href="http://imputationserver.readthedocs.io/en/latest/">here</a>.<br><br>If your input data is <b>GRCh37/hg19</b> please ensure chromosomes are encoded without prefix (e.g. <b>20</b>).<br>If your input data is <b>GRCh38hg38</b> please ensure chromosomes are encoded with prefix 'chr' (e.g. <b>chr20</b>).
version: 1.7.2
version: 1.7.3
website: https://imputationserver.readthedocs.io
category:

Expand Down
2 changes: 1 addition & 1 deletion files/imputationserver-hla.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
id: imputationserver-hla
name: Genotype Imputation HLA (Minimac4)
description: This is the new Michigan Imputation Server Pipeline using <a href="https://github.com/statgen/Minimac4">Minimac4</a>. Documentation can be found <a href="http://imputationserver.readthedocs.io/en/latest/">here</a>.<br><br>If your input data is <b>GRCh37/hg19</b> please ensure chromosomes are encoded without prefix (e.g. <b>20</b>).<br>If your input data is <b>GRCh38hg38</b> please ensure chromosomes are encoded with prefix 'chr' (e.g. <b>chr20</b>).
version: 1.7.2
version: 1.7.3
website: https://imputationserver.readthedocs.io
category:

Expand Down
2 changes: 1 addition & 1 deletion files/imputationserver-pgs.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
id: imputationserver-pgs
name: Genotype Imputation (PGS Calc Integration)
description: This is the new Michigan Imputation Server Pipeline using <a href="https://github.com/statgen/Minimac4">Minimac4</a>. Documentation can be found <a href="http://imputationserver.readthedocs.io/en/latest/">here</a>.<br><br>If your input data is <b>GRCh37/hg19</b> please ensure chromosomes are encoded without prefix (e.g. <b>20</b>).<br>If your input data is <b>GRCh38hg38</b> please ensure chromosomes are encoded with prefix 'chr' (e.g. <b>chr20</b>).
version: 1.7.2
version: 1.7.3
website: https://imputationserver.readthedocs.io
category:

Expand Down
2 changes: 1 addition & 1 deletion files/minimac4.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
id: imputationserver
name: Genotype Imputation (Minimac4)
description: This is the new Michigan Imputation Server Pipeline using <a href="https://github.com/statgen/Minimac4">Minimac4</a>. Documentation can be found <a href="http://imputationserver.readthedocs.io/en/latest/">here</a>.<br><br>If your input data is <b>GRCh37/hg19</b> please ensure chromosomes are encoded without prefix (e.g. <b>20</b>).<br>If your input data is <b>GRCh38hg38</b> please ensure chromosomes are encoded with prefix 'chr' (e.g. <b>chr20</b>).
version: 1.7.2
version: 1.7.3
website: https://imputationserver.readthedocs.io
category:

Expand Down
Loading

0 comments on commit 42ea3d8

Please sign in to comment.