diff options
author | Evan Read <eread@gitlab.com> | 2019-08-30 06:14:10 +0300 |
---|---|---|
committer | GitLab Release Tools Bot <delivery-team+release-tools@gitlab.com> | 2019-08-30 15:52:00 +0300 |
commit | 9fb5230fefff03b90a45c4caaccb57c80c6cf1bb (patch) | |
tree | 61d094b829d67ef05f239ac4ea0060f31e248f97 | |
parent | 14b67e94042c3b3757e95c47260947b388696d8d (diff) |
Merge branch 'revert-79fa2cd9' into 'master'
Revert "Merge branch 'nik-api-snippets-fix' into 'master'"
Closes #66673
See merge request gitlab-org/gitlab-ce!32295
(cherry picked from commit 98f2ab296a9b53b7e6fe467b50a9bcf9b75c6957)
5e0378b3 Revert "Merge branch 'nik-api-snippets-fix' into 'master'"
-rw-r--r-- | doc/api/snippets.md | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/doc/api/snippets.md b/doc/api/snippets.md index 1ce0b1e7a62..f90447e124e 100644 --- a/doc/api/snippets.md +++ b/doc/api/snippets.md @@ -165,15 +165,15 @@ Parameters: |:--------------|:-------|:---------|:---------------------------------------------------| | `title` | string | yes | Title of a snippet. | | `file_name` | string | yes | Name of a snippet file. | -| `code` | string | yes | Content of a snippet. | +| `content` | string | yes | Content of a snippet. | | `description` | string | no | Description of a snippet. | -| `visibility` | string | yes | Snippet's [visibility](#snippet-visibility-level). | +| `visibility` | string | no | Snippet's [visibility](#snippet-visibility-level). | Example request: ```sh curl --request POST \ - --data '{"title": "This is a snippet", "code": "Hello world", "description": "Hello World snippet", "file_name": "test.txt", "visibility": "internal" }' \ + --data '{"title": "This is a snippet", "content": "Hello world", "description": "Hello World snippet", "file_name": "test.txt", "visibility": "internal" }' \ --header 'Content-Type: application/json' \ --header "PRIVATE-TOKEN: valid_api_token" \ https://gitlab.example.com/api/v4/snippets @@ -222,14 +222,14 @@ Parameters: | `title` | string | no | Title of a snippet. | | `file_name` | string | no | Name of a snippet file. | | `description` | string | no | Description of a snippet. | -| `code` | string | no | Content of a snippet. | +| `content` | string | no | Content of a snippet. | | `visibility` | string | no | Snippet's [visibility](#snippet-visibility-level). | Example request: ```sh curl --request PUT \ - --data '{"title": "foo", "code": "bar"}' \ + --data '{"title": "foo", "content": "bar"}' \ --header 'Content-Type: application/json' \ --header "PRIVATE-TOKEN: valid_api_token" \ https://gitlab.example.com/api/v4/snippets/1 |