=== Helix Versioning Engine Branches [[get_helix_versioning_engine_v1_branches]] ==== `GET /helix_versioning_engine/v1/branches` Lists available branches in the system. The resources of this list are summaries of branches in the system. ===== 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_branches.html[`p4 -ztag branches`] command. For more field information refer to the http://www.perforce.com/perforce/doc.current/manuals/cmdref/p4_branches.html[command reference]. See <<error_responses>> for the format of failures. An example response body might look like: [source,json] ---- [ { "branch": "manually", "Update": "1437153920", "Access": "1437153920", "Owner": "jdoe", "Options": "unlocked", "Description": "Created by jdoe.\n" }, { "branch": "new_branch_CEUXQMYN", "Update": "1437164204", "Access": "1437164204", "Owner": "", "Options": "unlocked", "Description": "Something for the kids\n" } ] ---- ===== Ruby Client See link:./helix_web_services_client_ruby/HelixWebServicesClient.html#branches-instance_method[`HelixWebServicesClient#branches`] [[post_helix_versioning_engine_v1_branches]] ==== `POST /helix_versioning_engine/v1/branches` Creates a new branch specification, like the `p4 branch` command. There are no other parameters to this method. ===== 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_branch.html[p4 branch] command. ===== Response Headers [cols="2*", options="header"] |=== | Header Name | Notes | `Content-Type` | `application/json` |=== ===== Example Request JSON [source,json] ---- { "Branch": "my-project-main", "Description": "Branch my project from main to dev.\n", "View": ["//depot/main/my-project/... //depot/dev/my-project/..."] } ---- ==== Ruby Client Example [source,ruby] ---- client.create_branch({ "Branch" => "my-project-main", "Description" => "Branch my project from main to dev.\n", "View" => ["//depot/main/my-project/... //depot/dev/my-project/..."] }) ---- ===== Ruby Client See link:./helix_web_services_client_ruby/HelixWebServicesClient.html#create_branch-instance_method[`HelixWebServicesClient#create_branch`] [[get_helix_versioning_engine_v1_branches_branch]] ==== `GET /helix_versioning_engine/v1/branches/[branch]` Return branch details, similar to the `p4 branch -o` command. ===== Path Parameters [cols="5*", options="header"] |=== | Parameter | Description | Type | Parameter Type | Required | branch | The branch name. | string | path | Yes |=== ===== 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_branch.html[`p4 -ztag branch [branch 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] ---- { "Branch": "yagg-main", "Update": 1410907712, "Access": 1410907712, "Owner": "super", "Description": "Maintains a path from a development area to a main area.\n", "Options": "unlocked", "View": ["//depot/yagg/... //depot/main/yagg/..."] } ---- ===== Ruby Client See link:./helix_web_services_client_ruby/HelixWebServicesClient.html#branch-instance_method[`HelixWebServicesClient#branch`] [[patch_helix_versioning_engine_v1_branches_branch]] ==== `PATCH /helix_versioning_engine/v1/branches/[branch]` Update branch specifications, similar to the `p4 branch` command. Only the specified parameters in the body will be changed. ===== URL Parameters [cols="5*", options="header"] |=== | Parameter | Description | Type | Parameter Type | Required | branch | The name of the branch | string | path | Yes |=== ===== 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_branch.html[`p4 -ztag branch [branch name]`] command. ===== Response Headers [cols="2*", options="header"] |=== | Header Name | Notes | `Content-Type` | `application/json` |=== ===== Example JSON Request Body [source,json] ---- { "Description": "The updated my-project-main description.\n", "Owner": "saustin" } ---- ===== Ruby Client See link:./helix_web_services_client_ruby/HelixWebServicesClient.html#update_branch-instance_method[`HelixWebServicesClient#update_branch`] [source,ruby] ---- client.update_branch({ "Branch" => 'my_branch_id', "Description" => "The updated my-project-main description.\n", "Owner" => "saustin" }) ---- [[delete_helix_versioning_engine_v1_branches_branch]] ===== `DELETE /helix_versioning_engine/v1/branches/[branch]` Removes the branch specification, similar to the `p4 branch -d` command. ====== URL Parameters [cols="5*", options="header"] |=== | Parameter | Description | Type | Parameter Type | Required | branch | The name of the branch | string | path | Yes |=== ===== 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_branch-instance_method[`HelixWebServicesClient#delete_branch}`]
# | Change | User | Description | Committed | |
---|---|---|---|---|---|
#10 | 15144 | tjuricek |
Setup stream spec tests and documentation. Also revised the documentation folder http_p4_web_api -> helix_versioning_engine |
||
#9 | 15110 | tjuricek | Revise changes methods for new p4 connection handling, add server specs, remove model references in client, and update asciidoc documentation. | ||
#8 | 15090 | tjuricek |
Update _proposed_ API for project services. This is *very likely* to change, and will not be implemented until reviewed. |
||
#7 | 15078 | tjuricek |
clients spec method revisions Updated some other documentation. |
||
#6 | 15077 | tjuricek |
Add new 'model' technique, revised branch spec operations, test Auth::Middleware. The Ruby client now does *not* strictly type anything, but extends OpenStruct with helper methods to help deal with inconsistent data formats. See the OpenModel class documentation for more details. The Auth::Middleware class is also *finally* implemented as well. This does not take into account all possible variations of server behavior (yet), but that will happen in follow-up work. |
||
#5 | 15038 | tjuricek | Document 'login' auth method and client programming overview. | ||
#4 | 15032 | tjuricek |
Starting config and doc revisions. System is now broken while revisions underway. Configuration of the p4d connection is now done via a single HWSSettings middleware object injected into the Rack env. The HWSP4Cleanup middleware now cleans up any p4 injected into the Rack env. The Auth::App class now mostly just contains one method to generate a p4 ticket. /auth/v1/login. Added yard documentation for the main project. Yard docs have been reconfigured to dump into build/ directories. This should probably be done with each release. Hm... The top level rake file contains a task, 'all:doc', to update our documentation. This should probably be run for each checkin. Hm... Specs are now using Rack::Test on top of a 'live' p4d. I'd suggest you still use the p4util mechanism, which now dumps to a /tmp folder, so we can safely add P4IGNORE rules back into your local .p4config file. Old 'perforce' application now called 'helix_versioning_engine'. Removing cache data. Helix Sync may be slow. It may also get axed. We'll see. |
||
#3 | 14182 | tjuricek | Asciidoc conversion of the changes HTTP guide | ||
#2 | 13612 | tjuricek | Update deployment guide, switch built documentation to asciidoc, remove unused packaging script for p4_web_api | ||
#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. |