diff options
author | Toon Claes <toon@gitlab.com> | 2017-03-01 16:16:29 +0100 |
---|---|---|
committer | Toon Claes <toon@gitlab.com> | 2017-03-02 09:33:24 +0100 |
commit | b2c2dfe545526a1857e9605761f6d256ef73e190 (patch) | |
tree | ba3ec9ea7ce38a4c2ca09b6d92a3d67bb492daf1 /doc/api/project_snippets.md | |
parent | fc287191451bb6aac80d759ab521b5834d27df43 (diff) | |
download | gitlab-ce-b2c2dfe545526a1857e9605761f6d256ef73e190.tar.gz |
Expose Project's & ProjectSnippet's VisibilityLevel as String
Instead of exposing the VisibilityLevel as Integer, expose it as
String `visibility` for Project and ProjectSnippet.
Filter queries also accept the `visibility` as String instead of
`visibility_level` as Integer.
Also remove the `public` boolean.
Diffstat (limited to 'doc/api/project_snippets.md')
-rw-r--r-- | doc/api/project_snippets.md | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/doc/api/project_snippets.md b/doc/api/project_snippets.md index 404876f6237..4f6f561b83e 100644 --- a/doc/api/project_snippets.md +++ b/doc/api/project_snippets.md @@ -3,15 +3,15 @@ ### Snippet visibility level Snippets in GitLab can be either private, internal or public. -You can set it with the `visibility_level` field in the snippet. +You can set it with the `visibility` field in the snippet. Constants for snippet visibility levels are: -| Visibility | visibility_level | Description | -| ---------- | ---------------- | ----------- | -| Private | `0` | The snippet is visible only the snippet creator | -| Internal | `10` | The snippet is visible for any logged in user | -| Public | `20` | The snippet can be accessed without any authentication | +| visibility | Description | +| ---------- | ----------- | +| `private` | The snippet is visible only the snippet creator | +| `internal` | The snippet is visible for any logged in user | +| `public` | The snippet can be accessed without any authentication | ## List snippets @@ -71,7 +71,7 @@ Parameters: - `title` (required) - The title of a snippet - `file_name` (required) - The name of a snippet file - `code` (required) - The content of a snippet -- `visibility_level` (required) - The snippet's visibility +- `visibility` (required) - The snippet's visibility ## Update snippet @@ -88,7 +88,7 @@ Parameters: - `title` (optional) - The title of a snippet - `file_name` (optional) - The name of a snippet file - `code` (optional) - The content of a snippet -- `visibility_level` (optional) - The snippet's visibility +- `visibility` (optional) - The snippet's visibility ## Delete snippet |