Last active
August 29, 2015 14:12
-
-
Save m0sth8/812eb42fa3cf4b1d2cab to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// POST /api/tasks/ - create Scanning task and return task data | |
{ | |
"type": "docker" // | |
"options": { // common options for task | |
"timeout": 0 // task timeout, 0 - with no timeout | |
"proxy": "", // proxy settings | |
}, | |
"docker": { // configuration for docker task type | |
"image": "barbudo/wappalyzer", | |
"args": ["http://domain.com"], // arguments pushed to running container | |
} | |
} | |
// Possible headers | |
// X-Callback-Addr: url | |
// I'll sent POST request with task to this url if taks state is modified | |
// GET /api/tasks/ID - return task data | |
{ | |
"id": "long string" | |
"type": "docker" // | |
"options": { // common options for task | |
"timeout": 0 // task timeout, 0 - with no timeout | |
"proxy": "", // proxy settings | |
}, | |
"docker": { // configuration for docker task type | |
"image": "barbudo/wappalyzer", | |
"cmd": ["http://domain.com"], // arguments pushed to running container | |
} | |
"state": { | |
"status": "waiting|working|paused|done|error" | |
}, | |
"report": { | |
"type": "raw", | |
"raw": "string" // output from container | |
} | |
} | |
// GET /api/tasks/ID/report - 404 if report is not ready | |
{ | |
"type": "raw", | |
"raw": "string" // output from container | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment