Webhob REST API Tasks: Difference between revisions

From Yocto Project
Jump to navigationJump to search
(Created page with "Category:REST API Contracts === Endpoints === {| class="wikitable" |- ! Method !! Endpoint !! Body !! Description !! Comments |- | GET || /builds || JSON || Returns page si...")
 
No edit summary
Line 7: Line 7:
! Method !! Endpoint !! Body !! Description !! Comments
! Method !! Endpoint !! Body !! Description !! Comments
|-
|-
| GET || /builds || JSON || Returns page size limited and search criteria filtered amount of builds from the data base || -
| GET || /tasks || JSON || Returns page size limited and search criteria filtered amount of builds from the data base || -
|}
|}


Line 45: Line 45:
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span> || object || - || YES || - || - || -
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span> || object || - || YES || - || - || -
|-
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">outcome</span> || number || 2 || YES || - || Signals successful or failed build || 0 - the build has failed,<br /> 1 - successful build
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">build</span> || number || 2 || YES || - || Signals successful or failed build || 0 - the build has failed,<br /> 1 - successful build
|-
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">target</span> || string || - || YES || - || The name of the build target(s) || -
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">cpu_usage</span> || string || - || YES || - || The name of the build target(s) || -
|-
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">machine</span> || string array || - || YES || - || The selected hardware || -
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">disk_io</span> || string array || - || YES || - || The selected hardware || -
|-
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">started_on</span> || number representation of date || - || YES || - ||  Marks the moment the process is started || -
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">elapsed_time</span> || number representation of date || - || YES || - ||  Marks the moment the process is started || -
|-
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">completed_on</span> || number representation of date || - || YES || - || Marks the moment the process is completed || -
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">errors</span> || number representation of date || - || YES || - || Marks the moment the process is completed || -
|-
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">errors_no</span> || number || - || YES || - || Number of errors thrown by the build || -
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">errors_no</span> || number || - || YES || - || Number of errors thrown by the build || -
|-
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">warnings_no</span> || number || - || YES || - || Number of warnings thrown by the build || -
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">line_number</span> || number || - || YES || - || Number of warnings thrown by the build || -
|-
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">cooker_log_path</span> || string || - || YES || - || Path to log file || -
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">log_file</span> || string || - || YES || - || Path to log file || -
|-
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">image_fstypes</span> || string array || - || YES || - || The extensions of the root file systems produced by the build || -
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">order</span> || string array || - || YES || - || The extensions of the root file systems produced by the build || -
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">outcome</span> || string array || - || YES || - || The extensions of the root file systems produced by the build || -
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">path_to_sstate_obj</span> || string array || - || YES || - || The extensions of the root file systems produced by the build || -
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">py_stack_trace</span> || string array || - || YES || - || The extensions of the root file systems produced by the build || -
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">script_type</span> || string array || - || YES || - || The extensions of the root file systems produced by the build || -
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">source_url</span> || string array || - || YES || - || The extensions of the root file systems produced by the build || -
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">sstate_checksum</span> || string array || - || YES || - || The extensions of the root file systems produced by the build || -
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">sstate_result</span> || string array || - || YES || - || The extensions of the root file systems produced by the build || -
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">task_executed</span> || string array || - || YES || - || The extensions of the root file systems produced by the build || -
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">task_name</span> || string array || - || YES || - || The extensions of the root file systems produced by the build || -
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">warning</span> || string array || - || YES || - || The extensions of the root file systems produced by the build || -
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">warnings_no</span> || string array || - || YES || - || The extensions of the root file systems produced by the build || -
|-
| [Object Root].<span style="color:#FF9900">list[]</span>.<span style="color:#0066FF">fields</span>.<span style="color:#006600">work_directory</span> || string array || - || YES || - || The extensions of the root file systems produced by the build || -
|}
|}

Revision as of 16:02, 29 July 2013


Endpoints

Method Endpoint Body Description Comments
GET /tasks JSON Returns page size limited and search criteria filtered amount of builds from the data base -

Parameters

Name Type Description Comments
limit number The amout of builds to be displayed in one page -
offset number Represents the position of the first record in the page If limit is 1, end point will target the findOne functionality and the offset will act as the actual build id
search string Search string for all fields -
filter string Consists of a string used to filter results The general form: "<FIELD>:<VALUE>".
orderby string the name of the field that determens the soring of the resuls. "<FIELD>:<ORDER_DIRECTION>"

Response

Name Type Dimension Required Default value(s) Description Comments
[Object Root] object - YES - - -
[Object Root].count number - YES - Total amount of builds to be displayed (according to filter parameter) -
[Object Root].list object array - YES - - To describe a generic object element of the array,
the refference to it's root is "list[]"
[Object Root].list[].pk number - YES - - -
[Object Root].list[].model string - YES - - -
[Object Root].list[].fields object - YES - - -
[Object Root].list[].fields.build number 2 YES - Signals successful or failed build 0 - the build has failed,
1 - successful build
[Object Root].list[].fields.cpu_usage string - YES - The name of the build target(s) -
[Object Root].list[].fields.disk_io string array - YES - The selected hardware -
[Object Root].list[].fields.elapsed_time number representation of date - YES - Marks the moment the process is started -
[Object Root].list[].fields.errors number representation of date - YES - Marks the moment the process is completed -
[Object Root].list[].fields.errors_no number - YES - Number of errors thrown by the build -
[Object Root].list[].fields.line_number number - YES - Number of warnings thrown by the build -
[Object Root].list[].fields.log_file string - YES - Path to log file -
[Object Root].list[].fields.order string array - YES - The extensions of the root file systems produced by the build -
[Object Root].list[].fields.outcome string array - YES - The extensions of the root file systems produced by the build -
[Object Root].list[].fields.path_to_sstate_obj string array - YES - The extensions of the root file systems produced by the build -
[Object Root].list[].fields.py_stack_trace string array - YES - The extensions of the root file systems produced by the build -
[Object Root].list[].fields.script_type string array - YES - The extensions of the root file systems produced by the build -
[Object Root].list[].fields.source_url string array - YES - The extensions of the root file systems produced by the build -
[Object Root].list[].fields.sstate_checksum string array - YES - The extensions of the root file systems produced by the build -
[Object Root].list[].fields.sstate_result string array - YES - The extensions of the root file systems produced by the build -
[Object Root].list[].fields.task_executed string array - YES - The extensions of the root file systems produced by the build -
[Object Root].list[].fields.task_name string array - YES - The extensions of the root file systems produced by the build -
[Object Root].list[].fields.warning string array - YES - The extensions of the root file systems produced by the build -
[Object Root].list[].fields.warnings_no string array - YES - The extensions of the root file systems produced by the build -
[Object Root].list[].fields.work_directory string array - YES - The extensions of the root file systems produced by the build -