=== Helix Versioning Engine Labels [[get_helix_versioning_engine_vX_labels]] ==== `GET /helix_versioning_engine/v[api]/labels` Lists available labels in the system. The resources of this list are summaries of labels in the system. ===== Request URL Path Parameters [cols="2*", options="header"] |=== | Parameter | Description | `api` | The Helix Versioning Engine API level. |=== ===== Request Headers [cols="2*", options="header"] |=== | Header Name | Notes | `Authorization` | See <<authentication>> | `Accept` | `application/json` | `Content-Type` | `application/json` | `X-Perforce-Helix_Web_Services-*` | See <<per_request_configuration>> |=== ===== Response Headers [cols="2*", options="header"] |=== | Header Name | Notes | `Content-Type` | `application/json` |=== ===== Response Body JSON The values of this method are based on the result of the http://www.perforce.com/perforce/doc.current/manuals/cmdref/p4_labels.html[`p4 -ztag labels`] command. For more field information refer to the http://www.perforce.com/perforce/doc.current/manuals/cmdref/p4_labels.html[command reference]. See <<error_responses>> for the format of failures. An example response body might look like: [source,json] ---- [ { "label": "test-label", "Update": "1438120994", "Access": "1438120994", "Owner": "", "Options": "unlocked noautoreload", "Description": "The label for testing\n" } ] ---- ===== Ruby Client See link:./helix_web_services_client_ruby/HelixWebServicesClient.html#labels-instance_method[`HelixWebServicesClient#labels`] [[post_helix_versioning_engine_vX_labels]] ==== `POST /helix_versioning_engine/v[api]/labels` Creates a new label specification, like the `p4 label` command. There are no other parameters to this method. ===== Request URL Path Parameters [cols="2*", options="header"] |=== | Parameter | Description | `api` | The Helix Versioning Engine API level. |=== ===== Request Headers [cols="2*", options="header"] |=== | Header Name | Notes | `Authorization` | See <<authentication>> | `Accept` | `application/json` | `Content-Type` | `application/json` | `X-Perforce-Helix_Web_Services-*` | See <<per_request_configuration>> |=== ===== Request Body JSON Properties of the JSON object are the form fields of the http://www.perforce.com/perforce/doc.current/manuals/cmdref/p4_label.html[p4 label] command. For example: [source,json] ---- { "Label": "new_label", "Description": "A new label for stuff", "View": ["//depot/..."] } ---- ===== Response Headers [cols="2*", options="header"] |=== | Header Name | Notes | `Content-Type` | `application/json` |=== ===== Ruby Client See link:./helix_web_services_client_ruby/HelixWebServicesClient.html#create_label-instance_method[`HelixWebServicesClient#create_label`] [[get_helix_versioning_engine_vX_labels_label]] ==== `GET /helix_versioning_engine/v[api]/labels/[label]` Return label details, similar to the `p4 label -o` command. ===== Request URL Path Parameters [cols="2*", options="header"] |=== | Parameter | Description | `api` | The Helix Versioning Engine API level. | `label` | The label name. |=== ===== Request Headers [cols="2*", options="header"] |=== | Header Name | Notes | `Authorization` | See <<authentication>> | `Accept` | `application/json` | `Content-Type` | `application/json` | `X-Perforce-Helix_Web_Services-*` | See <<per_request_configuration>> |=== ===== Response Headers [cols="2*", options="header"] |=== | Header Name | Notes | `Content-Type` | `application/json` |=== ===== Response Data Returns the form fields of the http://www.perforce.com/perforce/doc.current/manuals/cmdref/p4_label.html[`p4 -ztag label [label name]`] command. For more information, see the command reference. The main difference between the details and list view is the inclusion of the View field. ===== Example JSON Response [source,json] ---- { "Label": "test-label", "Update": "2015/07/28 15:03:14", "Access": "2015/07/28 15:03:14", "Description": "The label for testing\n", "Options": "unlocked noautoreload", "View": [ "//depot/..." ] } ---- ===== Ruby Client See link:./helix_web_services_client_ruby/HelixWebServicesClient.html#label-instance_method[`HelixWebServicesClient#label`] [[patch_helix_versioning_engine_vX_labels_label]] ==== `PATCH /helix_versioning_engine/v[api]/labels/[label]` Update label specifications, similar to the `p4 label` command. Only the specified parameters in the body will be changed. ===== Request URL Path Parameters [cols="2*", options="header"] |=== | Parameter | Description | `api` | The Helix Versioning Engine API level. | `label` | The name of the label |=== ===== Request Headers [cols="2*", options="header"] |=== | Header Name | Notes | `Authorization` | See <<authentication>> | `Accept` | `application/json` | `Content-Type` | `application/json` | `X-Perforce-Helix_Web_Services-*` | See <<per_request_configuration>> |=== ===== Request Body JSON A single JSON object containing form fields of the http://www.perforce.com/perforce/doc.current/manuals/cmdref/p4_label.html[`p4 -ztag label [label name]`] command. ===== Response Headers [cols="2*", options="header"] |=== | Header Name | Notes | `Content-Type` | `application/json` |=== ===== Example JSON Request Body [source,json] ---- { "Description": "The updated new-label description.\n" } ---- ===== Ruby Client See link:./helix_web_services_client_ruby/HelixWebServicesClient.html#update_label-instance_method[`HelixWebServicesClient#update_label`] [[delete_helix_versioning_engine_vX_labels_label]] ===== `DELETE /helix_versioning_engine/v[api]/labels/[label]` Removes the label specification, similar to the `p4 label -d` command. ====== Request URL Path Parameters [cols="2*", options="header"] |=== | Parameter | Description | `api` | The Helix Versioning Engine API level. | `label` | The name of the label |=== ===== Request Headers [cols="2*", options="header"] |=== | Header Name | Notes | `Authorization` | See <<authentication>> | `Accept` | `application/json` | `Content-Type` | `application/json` | `X-Perforce-Helix_Web_Services-*` | See <<per_request_configuration>> |=== ===== Response Headers [cols="2*", options="header"] |=== | Header Name | Notes | `Content-Type` | `application/json` |=== ===== Ruby Client See link:./helix_web_services_client_ruby/HelixWebServicesClient.html#delete_label-instance_method[`HelixWebServicesClient#delete_label`]
# | Change | User | Description | Committed | |
---|---|---|---|---|---|
#1 | 15741 | ptomiak | Branch HWS for my use. | ||
//guest/perforce_software/helix-web-services/main/source/doc/helix_versioning_engine/labels.asc | |||||
#1 | 15622 | tjuricek |
Move source code to 'source/' subdirectory of branch. build/ will remain where it is. |
||
//guest/perforce_software/helix-web-services/main/doc/helix_versioning_engine/labels.asc | |||||
#3 | 15240 | tjuricek |
Set api level via request path on all Helix Versioning Engine methods. This will allow migration of applications to different P4D versions. Our internal methods (like project API) should attempt to handle backward compatibility similarly. P4WEBAPI-118 |
||
#2 | 15211 | tjuricek | Implement tests and documentation for label spec management. | ||
#1 | 15144 | tjuricek |
Setup stream spec tests and documentation. Also revised the documentation folder http_p4_web_api -> helix_versioning_engine |
||
//guest/perforce_software/helix-web-services/main/doc/http_p4_web_api/labels.asc | |||||
#1 | 13555 | tjuricek |
Starting Asciidoc conversion of documentation. Removed the "Shared Quality" document, that basically is online now at: https://confluence.perforce.com:8443/display/PWS/Quality+Assurance Adding some topology graphviz images used for online documentation. |