diff options
author | Job van der Voort <jobvandervoort@gmail.com> | 2015-04-21 17:21:51 +0300 |
---|---|---|
committer | Job van der Voort <jobvandervoort@gmail.com> | 2015-04-21 17:21:51 +0300 |
commit | a8e93b7f51d968c1380ed210499869b62b07fd15 (patch) | |
tree | c864e80dfd9cf4f83fcede678acc986e3a125bf5 /doc/api/labels.md | |
parent | 0625b15a481b3a3edd88110b3c18031ad9068d2f (diff) |
Version 7.10.0.rc5v7.10.0.rc5
Diffstat (limited to 'doc/api/labels.md')
-rw-r--r-- | doc/api/labels.md | 84 |
1 files changed, 0 insertions, 84 deletions
diff --git a/doc/api/labels.md b/doc/api/labels.md deleted file mode 100644 index de41f35d284..00000000000 --- a/doc/api/labels.md +++ /dev/null @@ -1,84 +0,0 @@ -# Labels - -## List labels - -Get all labels for given project. - -``` -GET /projects/:id/labels -``` - -```json -[ - { - "name": "Awesome", - "color": "#DD10AA" - }, - { - "name": "Documentation", - "color": "#1E80DD" - }, - { - "name": "Feature", - "color": "#11FF22" - }, - { - "name": "Bug", - "color": "#EE1122" - } -] -``` - -## Create a new label - -Creates a new label for given repository with given name and color. - -``` -POST /projects/:id/labels -``` - -Parameters: - -- `id` (required) - The ID of a project -- `name` (required) - The name of the label -- `color` (required) - Color of the label given in 6-digit hex notation with leading '#' sign (e.g. #FFAABB) - -It returns 200 and the newly created label, if the operation succeeds. -If the label already exists, 409 and an error message is returned. -If label parameters are invalid, 400 and an explaining error message is returned. - -## Delete a label - -Deletes a label given by its name. - -``` -DELETE /projects/:id/labels -``` - -- `id` (required) - The ID of a project -- `name` (required) - The name of the label to be deleted - -It returns 200 if the label successfully was deleted, 400 for wrong parameters -and 404 if the label does not exist. -In case of an error, additionally an error message is returned. - -## Edit an existing label - -Updates an existing label with new name or now color. At least one parameter -is required, to update the label. - -``` -PUT /projects/:id/labels -``` - -Parameters: - -- `id` (required) - The ID of a project -- `name` (required) - The name of the existing label -- `new_name` (optional) - The new name of the label -- `color` (optional) - New color of the label given in 6-digit hex notation with leading '#' sign (e.g. #FFAABB) - -On success, this method returns 200 with the updated label. -If required parameters are missing or parameters are invalid, 400 is returned. -If the label to be updated is missing, 404 is returned. -In case of an error, additionally an error message is returned. |