-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathapiary.apib
87 lines (71 loc) · 2.51 KB
/
apiary.apib
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
FORMAT: 1A
# OnCue
The OnCue API allows you to to interact programmatically with the [OnCue](https://github.com/michaelmarconi/oncue) *distributed job scheduling* service.
# Group Agents
Get information about all remote agents that are registered with the scheduler
## Agents Collection [/api/agents]
### List all Agents [GET]
+ Response 200 (application/json)
[{
"id": "akka://oncue-agent@localhost:55538/user/agent",
"url": "akka://oncue-agent@localhost:55538/user/agent"
}]
# Group Jobs
Get information about the state of all Jobs that have been enqueued in the system
## Jobs Collection [/api/jobs]
### List all Jobs [GET]
+ Response 200 (application/json)
[{
"enqueued_at": "2014-03-09T22:23:01.833Z",
"started_at": "2014-03-09T22:23:05.995Z",
"completed_at": "2014-03-09T22:23:06.006Z",
"error_message": null,
"id": 1,
"params": {
"expiration-age": "24 hours",
"include-failed-jobs": "true"
},
"progress": 1.0,
"rerun": false,
"state": "complete",
"worker_type": "oncue.worker.MaintenanceWorker"
}]
### Create a Job [POST]
+ Request (application/json)
{ "worker_type": "oncue.worker.TestWorker" }
+ Response 200 (application/json)
{
"enqueued_at": "2014-03-09T22:28:12.508Z",
"started_at": null,
"completed_at": null,
"error_message": null,
"id": 2,
"params": {},
"progress": 0.0,
"rerun": false,
"state": "queued",
"worker_type": "oncue.worker.TestWorker"
}
## Job [/api/jobs/{id}]
An individual job and all of its details
+ Parameters
+ id (required, number, `1`) ... Numeric `id` of the Job to perform the action with.
### Retrieve a Job [GET]
+ Response 200 (application/json)
{
"enqueued_at": "2014-03-09T22:23:01.833Z",
"started_at": "2014-03-09T22:23:05.995Z",
"completed_at": "2014-03-09T22:23:06.006Z",
"error_message": null,
"id": 1,
"params": {
"expiration-age": "24 hours",
"include-failed-jobs": "true"
},
"progress": 1.0,
"rerun": false,
"state": "complete",
"worker_type": "oncue.worker.MaintenanceWorker"
}
### Remove a Job [DELETE]
+ Response 200