Skip to content
Snippets Groups Projects
Commit 8fe58ed5 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets
Browse files

Merge pull request #2330 from gitlabhq/v4.0-api-fixes

V4.0 API fixes
parents 86673a66 eaa99478
No related branches found
No related tags found
No related merge requests found
:javascript
$(function() {
GitLab.GfmAutoComplete.Members.url = "#{ "/api/v2/projects/#{@project.id}/members" if @project }";
GitLab.GfmAutoComplete.Members.url = "#{ "/api/v3/projects/#{@project.id}/members" if @project }";
GitLab.GfmAutoComplete.Members.params.private_token = "#{current_user.private_token}";
 
GitLab.GfmAutoComplete.Emoji.data = #{raw emoji_autocomplete_source};
Loading
Loading
Loading
Loading
@@ -15,7 +15,7 @@ API requests should be prefixed with `api` and the API version. The API version
Example of a valid API request:
 
```
GET http://example.com/api/v2/projects?private_token=QVy1PB7sTxfy4pqfZM1U
GET http://example.com/api/v3/projects?private_token=QVy1PB7sTxfy4pqfZM1U
```
 
The API uses JSON to serialize data. You don't need to specify `.json` at the end of API URL.
Loading
Loading
Loading
Loading
@@ -78,7 +78,7 @@ GET /projects/:id/issues
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
 
## Single issue
 
Loading
Loading
@@ -90,7 +90,7 @@ GET /projects/:id/issues/:issue_id
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `issue_id` (required) - The ID of a project issue
 
```json
Loading
Loading
@@ -143,7 +143,7 @@ POST /projects/:id/issues
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `title` (required) - The title of an issue
+ `description` (optional) - The description of an issue
+ `assignee_id` (optional) - The ID of a user to assign issue
Loading
Loading
@@ -162,7 +162,7 @@ PUT /projects/:id/issues/:issue_id
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `issue_id` (required) - The ID of a project's issue
+ `title` (optional) - The title of an issue
+ `description` (optional) - The description of an issue
Loading
Loading
Loading
Loading
@@ -8,7 +8,7 @@ GET /projects/:id/merge_requests
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
 
```json
[
Loading
Loading
@@ -50,7 +50,7 @@ GET /projects/:id/merge_request/:merge_request_id
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `merge_request_id` (required) - The ID of MR
 
```json
Loading
Loading
@@ -92,7 +92,7 @@ POST /projects/:id/merge_requests
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `source_branch` (required) - The source branch
+ `target_branch` (required) - The target branch
+ `assignee_id` - Assignee user ID
Loading
Loading
@@ -136,7 +136,7 @@ PUT /projects/:id/merge_request/:merge_request_id
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `merge_request_id` (required) - ID of MR
+ `source_branch` - The source branch
+ `target_branch` - The target branch
Loading
Loading
@@ -182,7 +182,7 @@ POST /projects/:id/merge_request/:merge_request_id/comments
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `merge_request_id` (required) - ID of MR
+ `note` (required) - Text of comment
 
Loading
Loading
Loading
Loading
@@ -8,7 +8,7 @@ GET /projects/:id/milestones
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
 
## Single milestone
 
Loading
Loading
@@ -20,7 +20,7 @@ GET /projects/:id/milestones/:milestone_id
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `milestone_id` (required) - The ID of a project milestone
 
## New milestone
Loading
Loading
@@ -33,7 +33,7 @@ POST /projects/:id/milestones
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `milestone_id` (required) - The ID of a project milestone
+ `title` (required) - The title of an milestone
+ `description` (optional) - The description of the milestone
Loading
Loading
@@ -49,7 +49,7 @@ PUT /projects/:id/milestones/:milestone_id
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `milestone_id` (required) - The ID of a project milestone
+ `title` (optional) - The title of a milestone
+ `description` (optional) - The description of a milestone
Loading
Loading
Loading
Loading
@@ -28,7 +28,7 @@ GET /projects/:id/notes
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
 
### List issue notes
 
Loading
Loading
@@ -40,7 +40,7 @@ GET /projects/:id/issues/:issue_id/notes
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `issue_id` (required) - The ID of an issue
 
### List snippet notes
Loading
Loading
@@ -53,7 +53,7 @@ GET /projects/:id/snippets/:snippet_id/notes
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `snippet_id` (required) - The ID of a snippet
 
## Single note
Loading
Loading
@@ -68,7 +68,7 @@ GET /projects/:id/notes/:note_id
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `note_id` (required) - The ID of a wall note
 
### Single issue note
Loading
Loading
@@ -81,7 +81,7 @@ GET /projects/:id/issues/:issue_id/:notes/:note_id
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `issue_id` (required) - The ID of a project issue
+ `note_id` (required) - The ID of an issue note
 
Loading
Loading
@@ -95,7 +95,7 @@ GET /projects/:id/issues/:snippet_id/:notes/:note_id
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `snippet_id` (required) - The ID of a project snippet
+ `note_id` (required) - The ID of an snippet note
 
Loading
Loading
@@ -111,7 +111,7 @@ POST /projects/:id/notes
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `body` (required) - The content of a note
 
Will return created note with status `201 Created` on success, or `404 Not found` on fail.
Loading
Loading
@@ -127,7 +127,7 @@ POST /projects/:id/issues/:issue_id/notes
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `issue_id` (required) - The ID of an issue
+ `body` (required) - The content of a note
 
Loading
Loading
@@ -143,7 +143,7 @@ POST /projects/:id/snippets/:snippet_id/notes
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `snippet_id` (required) - The ID of an snippet
+ `body` (required) - The content of a note
 
Loading
Loading
Loading
Loading
@@ -10,7 +10,6 @@ GET /projects
[
{
"id": 3,
"code": "rails",
"name": "rails",
"description": null,
"path": "rails",
Loading
Loading
@@ -32,7 +31,6 @@ GET /projects
},
{
"id": 5,
"code": "gitlab",
"name": "gitlab",
"description": null,
"path": "gitlab",
Loading
Loading
@@ -65,12 +63,11 @@ GET /projects/:id
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
 
```json
{
"id": 5,
"code": "gitlab",
"name": "gitlab",
"description": null,
"path": "gitlab",
Loading
Loading
@@ -103,7 +100,6 @@ POST /projects
Parameters:
 
+ `name` (required) - new project name
+ `code` (optional) - new project code, uses project name if not set
+ `path` (optional) - new project path, uses project name if not set
+ `description` (optional) - short project description
+ `default_branch` (optional) - 'master' by default
Loading
Loading
@@ -125,7 +121,7 @@ GET /projects/:id/members
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `query` - Query string
 
## Get project team member
Loading
Loading
@@ -138,7 +134,7 @@ GET /projects/:id/members/:user_id
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `user_id` (required) - The ID of a user
 
```json
Loading
Loading
@@ -164,7 +160,7 @@ POST /projects/:id/members
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `user_id` (required) - The ID of a user to add
+ `access_level` (required) - Project access level
 
Loading
Loading
@@ -180,7 +176,7 @@ PUT /projects/:id/members/:user_id
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `user_id` (required) - The ID of a team member
+ `access_level` (required) - Project access level
 
Loading
Loading
@@ -196,7 +192,7 @@ DELETE /projects/:id/members/:user_id
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `user_id` (required) - The ID of a team member
 
Status code `200` will be returned on success.
Loading
Loading
@@ -211,7 +207,7 @@ GET /projects/:id/hooks
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
 
Will return hooks with status `200 OK` on success, or `404 Not found` on fail.
 
Loading
Loading
@@ -225,7 +221,7 @@ GET /projects/:id/hooks/:hook_id
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `hook_id` (required) - The ID of a project hook
 
Will return hook with status `200 OK` on success, or `404 Not found` on fail.
Loading
Loading
@@ -240,7 +236,7 @@ POST /projects/:id/hooks
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `url` (required) - The hook URL
 
Will return status `201 Created` on success, or `404 Not found` on fail.
Loading
Loading
@@ -255,7 +251,7 @@ PUT /projects/:id/hooks/:hook_id
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `hook_id` (required) - The ID of a project hook
+ `url` (required) - The hook URL
 
Loading
Loading
@@ -272,7 +268,7 @@ DELETE /projects/:id/hooks
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `hook_id` (required) - The ID of hook to delete
 
Will return status `200 OK` on success, or `404 Not found` on fail.
Loading
Loading
@@ -8,7 +8,7 @@ GET /projects/:id/repository/branches
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
 
```json
[
Loading
Loading
@@ -48,7 +48,7 @@ GET /projects/:id/repository/branches/:branch
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `branch` (required) - The name of the branch
 
```json
Loading
Loading
@@ -87,7 +87,7 @@ GET /projects/:id/repository/tags
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
 
```json
[
Loading
Loading
@@ -125,7 +125,7 @@ GET /projects/:id/repository/commits
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `ref_name` (optional) - The name of a repository branch or tag
 
```json
Loading
Loading
@@ -159,7 +159,7 @@ GET /projects/:id/repository/commits/:sha/blob
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `sha` (required) - The commit or branch name
+ `filepath` (required) - The path the file
 
Loading
Loading
Loading
Loading
@@ -8,7 +8,7 @@ GET /projects/:id/snippets
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
 
## Single snippet
 
Loading
Loading
@@ -20,7 +20,7 @@ GET /projects/:id/snippets/:snippet_id
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `snippet_id` (required) - The ID of a project's snippet
 
```json
Loading
Loading
@@ -52,7 +52,7 @@ GET /projects/:id/snippets/:snippet_id/raw
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `snippet_id` (required) - The ID of a project's snippet
 
## New snippet
Loading
Loading
@@ -65,7 +65,7 @@ POST /projects/:id/snippets
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `title` (required) - The title of a snippet
+ `file_name` (required) - The name of a snippet file
+ `lifetime` (optional) - The expiration date of a snippet
Loading
Loading
@@ -83,7 +83,7 @@ PUT /projects/:id/snippets/:snippet_id
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `snippet_id` (required) - The ID of a project's snippet
+ `title` (optional) - The title of a snippet
+ `file_name` (optional) - The name of a snippet file
Loading
Loading
@@ -102,7 +102,7 @@ DELETE /projects/:id/snippets/:snippet_id
 
Parameters:
 
+ `id` (required) - The ID or code name of a project
+ `id` (required) - The ID of a project
+ `snippet_id` (required) - The ID of a project's snippet
 
Status code `200` will be returned on success.
Loading
Loading
Loading
Loading
@@ -2,7 +2,7 @@ Dir["#{Rails.root}/lib/api/*.rb"].each {|file| require file}
 
module Gitlab
class API < Grape::API
version 'v2', using: :path
version 'v3', using: :path
 
rescue_from ActiveRecord::RecordNotFound do
rack_response({'message' => '404 Not found'}.to_json, 404)
Loading
Loading
Loading
Loading
@@ -18,7 +18,7 @@ module Gitlab
end
 
class Project < Grape::Entity
expose :id, :code, :name, :description, :path, :default_branch
expose :id, :name, :description, :path, :default_branch
expose :owner, using: Entities::UserBasic
expose :private_flag, as: :private
expose :issues_enabled, :merge_requests_enabled, :wall_enabled, :wiki_enabled, :created_at
Loading
Loading
Loading
Loading
@@ -17,7 +17,7 @@ module Gitlab
# Get a list of project issues
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# Example Request:
# GET /projects/:id/issues
get ":id/issues" do
Loading
Loading
@@ -27,7 +27,7 @@ module Gitlab
# Get a single project issue
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# issue_id (required) - The ID of a project issue
# Example Request:
# GET /projects/:id/issues/:issue_id
Loading
Loading
@@ -39,7 +39,7 @@ module Gitlab
# Create a new project issue
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# title (required) - The title of an issue
# description (optional) - The description of an issue
# assignee_id (optional) - The ID of a user to assign issue
Loading
Loading
@@ -62,7 +62,7 @@ module Gitlab
# Update an existing issue
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# issue_id (required) - The ID of a project issue
# title (optional) - The title of an issue
# description (optional) - The description of an issue
Loading
Loading
@@ -88,7 +88,7 @@ module Gitlab
# Delete a project issue (deprecated)
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# issue_id (required) - The ID of a project issue
# Example Request:
# DELETE /projects/:id/issues/:issue_id
Loading
Loading
Loading
Loading
@@ -8,7 +8,7 @@ module Gitlab
# List merge requests
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
#
# Example:
# GET /projects/:id/merge_requests
Loading
Loading
@@ -22,7 +22,7 @@ module Gitlab
# Show MR
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# merge_request_id (required) - The ID of MR
#
# Example:
Loading
Loading
@@ -40,7 +40,7 @@ module Gitlab
#
# Parameters:
#
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# source_branch (required) - The source branch
# target_branch (required) - The target branch
# assignee_id - Assignee user ID
Loading
Loading
@@ -67,7 +67,7 @@ module Gitlab
# Update MR
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# merge_request_id (required) - ID of MR
# source_branch - The source branch
# target_branch - The target branch
Loading
Loading
@@ -95,7 +95,7 @@ module Gitlab
# Post comment to merge request
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# merge_request_id (required) - ID of MR
# note (required) - Text of comment
# Examples:
Loading
Loading
Loading
Loading
@@ -7,7 +7,7 @@ module Gitlab
# Get a list of project milestones
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# Example Request:
# GET /projects/:id/milestones
get ":id/milestones" do
Loading
Loading
@@ -19,7 +19,7 @@ module Gitlab
# Get a single project milestone
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# milestone_id (required) - The ID of a project milestone
# Example Request:
# GET /projects/:id/milestones/:milestone_id
Loading
Loading
@@ -33,7 +33,7 @@ module Gitlab
# Create a new project milestone
#
# Parameters:
# id (required) - The ID or code name of the project
# id (required) - The ID of the project
# title (required) - The title of the milestone
# description (optional) - The description of the milestone
# due_date (optional) - The due date of the milestone
Loading
Loading
@@ -54,7 +54,7 @@ module Gitlab
# Update an existing project milestone
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# milestone_id (required) - The ID of a project milestone
# title (optional) - The title of a milestone
# description (optional) - The description of a milestone
Loading
Loading
Loading
Loading
@@ -9,7 +9,7 @@ module Gitlab
# Get a list of project wall notes
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# Example Request:
# GET /projects/:id/notes
get ":id/notes" do
Loading
Loading
@@ -20,7 +20,7 @@ module Gitlab
# Get a single project wall note
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# note_id (required) - The ID of a note
# Example Request:
# GET /projects/:id/notes/:note_id
Loading
Loading
@@ -32,7 +32,7 @@ module Gitlab
# Create a new project wall note
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# body (required) - The content of a note
# Example Request:
# POST /projects/:id/notes
Loading
Loading
@@ -54,7 +54,7 @@ module Gitlab
# Get a list of project +noteable+ notes
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# noteable_id (required) - The ID of an issue or snippet
# Example Request:
# GET /projects/:id/issues/:noteable_id/notes
Loading
Loading
@@ -67,7 +67,7 @@ module Gitlab
# Get a single +noteable+ note
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# noteable_id (required) - The ID of an issue or snippet
# note_id (required) - The ID of a note
# Example Request:
Loading
Loading
@@ -82,7 +82,7 @@ module Gitlab
# Create a new +noteable+ note
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# noteable_id (required) - The ID of an issue or snippet
# body (required) - The content of a note
# Example Request:
Loading
Loading
Loading
Loading
@@ -16,7 +16,7 @@ module Gitlab
# Get a single project
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# Example Request:
# GET /projects/:id
get ":id" do
Loading
Loading
@@ -27,7 +27,6 @@ module Gitlab
#
# Parameters:
# name (required) - name for new project
# code (optional) - code for new project, uses project name if not set
# path (optional) - path for new project, uses project name if not set
# description (optional) - short project description
# default_branch (optional) - 'master' by default
Loading
Loading
@@ -56,7 +55,7 @@ module Gitlab
# Get a project team members
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# query - Query string
# Example Request:
# GET /projects/:id/members
Loading
Loading
@@ -72,7 +71,7 @@ module Gitlab
# Get a project team members
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# user_id (required) - The ID of a user
# Example Request:
# GET /projects/:id/members/:user_id
Loading
Loading
@@ -84,7 +83,7 @@ module Gitlab
# Add a new project team member
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# user_id (required) - The ID of a user
# access_level (required) - Project access level
# Example Request:
Loading
Loading
@@ -107,7 +106,7 @@ module Gitlab
# Update project team member
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# user_id (required) - The ID of a team member
# access_level (required) - Project access level
# Example Request:
Loading
Loading
@@ -127,7 +126,7 @@ module Gitlab
# Remove a team member from project
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# user_id (required) - The ID of a team member
# Example Request:
# DELETE /projects/:id/members/:user_id
Loading
Loading
@@ -140,7 +139,7 @@ module Gitlab
# Get project hooks
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# Example Request:
# GET /projects/:id/hooks
get ":id/hooks" do
Loading
Loading
@@ -152,7 +151,7 @@ module Gitlab
# Get a project hook
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# hook_id (required) - The ID of a project hook
# Example Request:
# GET /projects/:id/hooks/:hook_id
Loading
Loading
@@ -165,7 +164,7 @@ module Gitlab
# Add hook to project
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# url (required) - The hook URL
# Example Request:
# POST /projects/:id/hooks
Loading
Loading
@@ -182,7 +181,7 @@ module Gitlab
# Update an existing project hook
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# hook_id (required) - The ID of a project hook
# url (required) - The hook URL
# Example Request:
Loading
Loading
@@ -203,7 +202,7 @@ module Gitlab
# Delete project hook
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# hook_id (required) - The ID of hook to delete
# Example Request:
# DELETE /projects/:id/hooks
Loading
Loading
@@ -216,7 +215,7 @@ module Gitlab
# Get a project repository branches
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# Example Request:
# GET /projects/:id/repository/branches
get ":id/repository/branches" do
Loading
Loading
@@ -226,7 +225,7 @@ module Gitlab
# Get a single branch
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# branch (required) - The name of the branch
# Example Request:
# GET /projects/:id/repository/branches/:branch
Loading
Loading
@@ -238,7 +237,7 @@ module Gitlab
# Get a project repository tags
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# Example Request:
# GET /projects/:id/repository/tags
get ":id/repository/tags" do
Loading
Loading
@@ -248,7 +247,7 @@ module Gitlab
# Get a project repository commits
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# ref_name (optional) - The name of a repository branch or tag
# Example Request:
# GET /projects/:id/repository/commits
Loading
Loading
@@ -266,7 +265,7 @@ module Gitlab
# Get a project snippets
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# Example Request:
# GET /projects/:id/snippets
get ":id/snippets" do
Loading
Loading
@@ -276,7 +275,7 @@ module Gitlab
# Get a project snippet
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# snippet_id (required) - The ID of a project snippet
# Example Request:
# GET /projects/:id/snippets/:snippet_id
Loading
Loading
@@ -288,7 +287,7 @@ module Gitlab
# Create a new project snippet
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# title (required) - The title of a snippet
# file_name (required) - The name of a snippet file
# lifetime (optional) - The expiration date of a snippet
Loading
Loading
@@ -314,7 +313,7 @@ module Gitlab
# Update an existing project snippet
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# snippet_id (required) - The ID of a project snippet
# title (optional) - The title of a snippet
# file_name (optional) - The name of a snippet file
Loading
Loading
@@ -340,7 +339,7 @@ module Gitlab
# Delete a project snippet
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# snippet_id (required) - The ID of a project snippet
# Example Request:
# DELETE /projects/:id/snippets/:snippet_id
Loading
Loading
@@ -354,7 +353,7 @@ module Gitlab
# Get a raw project snippet
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# snippet_id (required) - The ID of a project snippet
# Example Request:
# GET /projects/:id/snippets/:snippet_id/raw
Loading
Loading
@@ -367,7 +366,7 @@ module Gitlab
# Get a raw file contents
#
# Parameters:
# id (required) - The ID or code name of a project
# id (required) - The ID of a project
# sha (required) - The commit or branch name
# filepath (required) - The path to the file to display
# Example Request:
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment