API
- GET /script
List Scripts
Return a list of the available scripts
- Query Parameters:
page (integer) – A page number within the paginated result set
page_size (integer) – Number of results to return per page
- Status Codes:
200 OK – (Ok) given script exists, parameters are returned
404 Not Found – (Not found) given script does not exist
- Response JSON Object:
count (integer) – Number of found scripts
next (string) – URI to the next page
previous (string) – URI to the previous page
results[].command (string) – Command to be executed
results[].groups[] (any) –
results[].is_array (boolean) – If is an array of jobs
results[].is_output_visible (boolean) – If the output files are visible
results[].job (string) – DRM job template assigned
results[].max_clock_time (string) – Timeout for its running time
results[].name (string) – Unique name of the script to submit
results[].param[] (any) –
- GET /script/{name}
Get Script
Return parameters, type and validation for given script
- Parameters:
name (string) – Unique name of the script
name – Unique name of the script
- Status Codes:
200 OK – (Ok) given script exists, parameters are returned
404 Not Found – (Not found) given script does not exist
- Response JSON Object:
command (string) – Command to be executed
groups[] (any) –
is_array (boolean) – If is an array of jobs
is_output_visible (boolean) – If the output files are visible
job (string) – DRM job template assigned
max_clock_time (string) – Timeout for its running time
name (string) – Unique name of the script to submit
param[] (any) –
- POST /task
Create Task
Submit a new task to the DRM
- Status Codes:
201 Created – (Created) given task has been submitted
400 Bad Request – (Bad request) given parameters do not satisfy any task specification
403 Forbidden – (Forbidden) your request cannot be submitted
500 Internal Server Error – (Internal server error) given task could not start
- Response JSON Object:
creation_date (string) – Timestamp of the creation
deleted (boolean) – If the task is deleted
dependency_type (string) – Type of dependency
depends_on[] (string) –
drm_job_id (string) – Internal id of the job in the DRM
files_name (object) – Mapping of the provided files in the current task
param[] (any) –
sender_ip_addr (string) – IP address of the sender
status (string) – Current status of the task
task_name (string) – Name of the script used in this task
update_date (string) – Timestamp of the last update
uuid (string) – Unique ID of the current task
- DELETE /task/{uuid}
Delete Task
Delete given task, if any
- Parameters:
uuid (string) – Unique ID of the task
- Status Codes:
204 No Content – (No content) task has been deleted
403 Forbidden – (Forbidden) your request cannot be fulfilled
404 Not Found – (Not found) task does not exist
500 Internal Server Error – (Internal server error) the task was not deleted for whatever reason
- Response JSON Object:
creation_date (string) – Timestamp of the creation
deleted (boolean) – If the task is deleted
dependency_type (string) – Type of dependency
depends_on[] (string) –
drm_job_id (string) – Internal id of the job in the DRM
files_name (object) – Mapping of the provided files in the current task
param[] (any) –
sender_ip_addr (string) – IP address of the sender
status (string) – Current status of the task
task_name (string) – Name of the script used in this task
update_date (string) – Timestamp of the last update
uuid (string) – Unique ID of the current task
- GET /task/{uuid}
Get Task
Retrieve details of the given task
- Parameters:
uuid (string) – Unique ID of the task
- Status Codes:
200 OK – (Ok) task has been retrieved
403 Forbidden – (Forbidden) your request cannot be fulfilled
404 Not Found – (Not found) task does not exist
- Response JSON Object:
creation_date (string) – Timestamp of the creation
deleted (boolean) – If the task is deleted
dependency_type (string) – Type of dependency
depends_on[] (string) –
drm_job_id (string) – Internal id of the job in the DRM
files_name (object) – Mapping of the provided files in the current task
param[] (any) –
sender_ip_addr (string) – IP address of the sender
status (string) – Current status of the task
task_name (string) – Name of the script used in this task
update_date (string) – Timestamp of the last update
uuid (string) – Unique ID of the current task
- GET /task/{uuid}/download
Download Task
Download current working dir as zip of the given task
- Parameters:
uuid (string) – Unique ID of the task
- Status Codes:
200 OK – (Ok) task has been retrieved
403 Forbidden – (Forbidden) your request cannot be fulfilled
404 Not Found – (Not found) task does not exist
- GET /task/{uuid}/file
List Task Files
Get the content of the working directory as a list of files
- Parameters:
uuid (string) – Unique ID of the task
- Status Codes:
200 OK – (Ok)
403 Forbidden – (Forbidden) your request cannot be fulfilled
404 Not Found – (Not found) task does not exist
- Response JSON Object:
[] (string) –
- GET /token/{username}
Get User Token
Exchanges external/OAuth2 access token with an internal one. It uses email for granting access to authenticated users. Therefore, requesting application is responsible for providing an access token with enough information (for now, email address is required).
- Parameters:
username (string) – unique ID of the user trying to authenticate
- Status Codes:
200 OK – (Ok) you have been authenticated by external service
403 Forbidden – (Forbidden) your request has been refused by external authentication service