Find and Download Workflows

Login

Using the Website

  • browse the inventory or use the search feature
  • select a workflow you are interested in.
  • Click on download. You will recieve a zip-archive. Unpack it to your preferred destination.

Using the API

Get All Workflows

Bash

1
2
3
4
curl  -X GET \
  'https://workflows.material-digital.de/api/v1/resources/workflows' \
  --header 'Accept: */*' \
  --header 'Authorization: Bearer <your-api-key>'

Python

1
2
3
4
5
6
7
8
9
import requests

reqUrl = "https://workflows.material-digital.de/api/v1/resources/workflows"
headersList = {
 "Accept": "*/*",
 "Authorization": "Bearer <your-api-token>" 
}
response = requests.request("GET", reqUrl, headers=headersList)
print(response.text)

Result:

1
2
3
4
5
6
7
8
9
10
[
  {
    "id": 20,
    "name": "Test-WaNo",
    "url": "https://github.com/KIT-Workflows/Test-WaNo",
    "version": "version",
    "description": "This WaNo shows the most used functionalities available within the SimStack workflow framework."
  },
  ...
]

Download a Single Workflow

Bash

1
2
3
4
5
curl  -X GET \
  'https://workflows.material-digital.de/api/v1/resources/workflows/<workflow-id>' \
  --header 'Accept: */*' \
  --header 'Authorization: Bearer <your-api-key>'
  -O

Python

1
2
3
4
5
6
7
8
9
10
11
12
13
import requests

reqUrl = "https://workflows.material-digital.de/api/v1/resources/<workflow-id>"
save_path = "target/path/file.zip"
headersList = {
 "Accept": "*/*",
 "Authorization": "Bearer <your-api-token>" 
}

r = requests.get(url, headers=headersList, stream=True)
with open(save_path, 'wb') as fd:
    for chunk in r.iter_content(chunk_size=chunk_size):
        fd.write(chunk)

Back to top

Copyright © BMBF Plattform MaterialDigital, 2021.