Skip to content

Instantly share code, notes, and snippets.

@mtorrisi
mtorrisi / 1-create-task-curl
Created November 16, 2016 14:11
Create Futuregateway task
## COMMAND
curl -i -H "Content-Type: application/json" -X POST -d '{"application":"2","description":"sayhello@csgfsdk test run", "arguments": ["\"I am saying hello!\""], "output_files": [{"name":"sayhello.data"}], "input_files": [{"name":"sayhello.sh"},{"name":"sayhello.txt"}]}' http://151.97.41.44:8888/v1.0/tasks?user=user
## EXPECTED OUTPUT
{
"status": "WAITING",
"application": "2",
"date": "2016-11-16T09:28:47Z",
"description": "sayhello@csgfsdk test run",
"output_files": [
@mtorrisi
mtorrisi / 3-check-status-curl
Last active November 16, 2016 14:12
Get task status
## COMMAND
curl -X GET "http://151.97.41.66:8888/v1.0/tasks/16"
## EXPECTED OUTPUT
{
"last_change": "2016-11-16T09:31:33Z",
"input_files": [
{
"name": "sayhello.sh",
"url": "file?path=%2Ftmp%2F137e989e-abdf-11e6-b19b-fa163e72d9ab&name=sayhello.sh",