Auto-tools/Projects/MozPool: Difference between revisions

Jump to navigation Jump to search
Line 43: Line 43:
= API =
= API =


<id> can be "all" or "any" for most apis (except release)
The API is documented along with that of LifeGuard at http://hg.mozilla.org/build/bmm/file/default/API.txt
* (future) can include json body with "filter" property and these subproperties:
** type: phone, panda, tegra (?)
** model
** os
* "all" returns all matching devices, "any" returns a random one
 
/api/device/
* lists all devices
 
/api/device/<id>/
* info on device <id>.
 
/api/device/<id>/request/ (POST)
* requests device <id>. device is only returned if state is IDLE.
** can have following json properties in body:
** fennec: fennec build ID (path?)
*** Installs build before returning device
** b2g: b2g build ID (?)
*** Flashes build before returning device
** callback: IP address and port, for asynchronous notification
 
If 'callback' is not given, waits until the build is installed and device
verified, then sends back device info with new state (200 if state is ASSIGNED,
other code otherwise). If callback given, responds with 200 OK then calls
callback when device is ready (or errored) with JSON result
 
* EDIT: callback probably needs to be mandatory
 
/api/device/<id>/release/
* releases device <id>.
** can have following json property:
*** state: should be IDLE or ASSIGNED or particular error
 
/api/device/<id>/verify/
* launches a verify operation on device (same as when device is assigned)
Confirmed users
1,927

edits

Navigation menu