Partek Flow Documentation

Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The API reference documentation is available here:  Manual for Partek Flow's REST API Command List

The public key and Python libraries are available here:  PartekFlow-REST.zip

 

Generate an authentication token 

An access token can be generated from the System information section of the settings page. 

...

curl --form username=admin --form encrypt=RSA --form password=cUOWY0VvkSFagr... http://localhost:8080/flow/api/v1/users/list

Upload and analyze a group of samples.

Get the name of a pipeline from the GUI or from the API

...

python UploadSamples.py -v --server http://localhost:8080 --user admin --password [access token] --files ~/sample1.fastq.gz ~/sample2.fastq.gz --project ProjectName --pipeline AlignAndQuantify --inputs 28061,145855

Add a collaborator to a project

curl -X PUT "http://localhost:8080/flow/api/v1/projects?project=ProjectName&collaborator=user1&role=Collaborator&username=admin&encrypt=RSA&password=[url encoded token]"

Monitor a folder and upload files as they are created

Code Block
#!/bin/bash
inotifywait -m $PATH_TO_MONITOR -e create -e moved_to |
  while read path action file; do
      if [[ $file == *.fastq.gz ]]; then
              echo "Uploading $file"
              python UploadSamples.py -v --server $SERVER --user $USER --password $TOKEN --files $path/$file --project "$PROJECT" 
      fi
  done

...