Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorJeremy Anderson <jeremy@code-adept.com>2012-07-26 18:29:53 +0400
committerJeremy Anderson <jeremy@code-adept.com>2012-07-31 18:32:44 +0400
commit69c4cea65a7ba13469f43914fbdccf592053fec8 (patch)
treea93056eb77da46e7fd7d6aecca27938a82b172c5 /doc
parente6edaa3b502090f461b58c439ea476da2d37f039 (diff)
updating project api to include raw blob contents and single branch
Diffstat (limited to 'doc')
-rw-r--r--doc/api/projects.md53
1 files changed, 53 insertions, 0 deletions
diff --git a/doc/api/projects.md b/doc/api/projects.md
index cd94cd42328..1475fbec23a 100644
--- a/doc/api/projects.md
+++ b/doc/api/projects.md
@@ -129,6 +129,43 @@ Parameters:
]
```
+Get a single project repository branch.
+
+```
+GET /projects/:id/repository/branches/:branch
+```
+
+Parameters:
+
++ `id` (required) - The ID or code name of a project
++ `branch` (required) - The name of the branch
+
+```json
+{
+ "name": "master",
+ "commit": {
+ "id": "7b5c3cc8be40ee161ae89a06bba6229da1032a0c",
+ "parents": [
+ {
+ "id": "4ad91d3c1144c406e50c7b33bae684bd6837faf8"
+ }
+ ],
+ "tree": "46e82de44b1061621357f24c05515327f2795a95",
+ "message": "add projects API",
+ "author": {
+ "name": "John Smith",
+ "email": "john@example.com"
+ },
+ "committer": {
+ "name": "John Smith",
+ "email": "john@example.com"
+ },
+ "authored_date": "2012-06-27T05:51:39-07:00",
+ "committed_date": "2012-06-28T03:44:20-07:00"
+ }
+}
+```
+
## Project repository tags
Get a list of project repository tags sorted by name in reverse alphabetical order.
@@ -268,3 +305,19 @@ Parameters:
+ `snippet_id` (required) - The ID of a project's snippet
Status code `200` will be returned on success.
+
+## Raw blob content
+
+Get the raw file contents for a file.
+
+```
+GET /projects/:id/repository/commits/:sha/blob
+```
+
+Parameters:
+
++ `id` (required) - The ID or code name of a project
++ `sha` (required) - The commit or branch name
++ `filepath` (required) - The path th the file
+
+Will return the raw file contents.