V3 to V4 version
Since GitLab 9.0, API V4 is the preferred version to be used.
V3 will remain working until at least GitLab 9.3. The V3 API documentation is still available.
Below are the changes made between V3 and V4.
8.17
- Removed
GET /projects/:search(use:GET /projects?search=x) !8877 -
iidfilter has been removed fromGET /projects/:id/issues!8967 -
GET /projects/:id/merge_requests?iid[]=x&iid[]=yarray filter has been renamed toiids!8793 - Endpoints under
GET /projects/merge_request/:idhave been removed (use:GET /projects/merge_requests/:id) !8793 - Project snippets do not return deprecated field
expires_at!8723 - Endpoints under
GET /projects/:id/keyshave been removed (useGET /projects/:id/deploy_keys) !8716
9.0
- Status 409 returned for
POST /projects/:id/memberswhen a member already exists !9093 - Moved
DELETE /projects/:id/startoPOST /projects/:id/unstar!9328 - Removed the following deprecated Templates endpoints (these are still accessible with
/templatesprefix) !8853/licences/licences/:key/gitignores/gitlab_ci_ymls/dockerfiles/gitignores/:key/gitlab_ci_ymls/:key/dockerfiles/:key
- Moved
POST /projects/fork/:idtoPOST /projects/:id/fork!8940 - Moved
DELETE /todostoPOST /todos/mark_as_doneandDELETE /todos/:todo_idtoPOST /todos/:todo_id/mark_as_done!9410 - Project filters are no longer available as
GET /projects/foo, but asGET /projects?foo=trueinstead !8962-
GET /projects/visible&GET /projects/allare consolidated intoGET /projectsand can be used with or without authorization -
GET /projects/ownedmoved toGET /projects?owned=true -
GET /projects/starredmoved toGET /projects?starred=true
-
-
GET /projectsreturns all projects visible to current user, even if the user is not a member !9674- To get projects the user is a member of, use
GET /projects?membership=true
- To get projects the user is a member of, use
- Return pagination headers for all endpoints that return an array !8606
- Added
POST /environments/:environment_id/stopto stop an environment !8808 - Removed
DELETE /projects/:id/deploy_keys/:key_id/disable. UseDELETE /projects/:id/deploy_keys/:key_idinstead !9366 - Moved
PUT /users/:id/(block|unblock)toPOST /users/:id/(block|unblock)!9371 - Make subscription API more RESTful. Use
POST /projects/:id/:subscribable_type/:subscribable_id/subscribeto subscribe andPOST /projects/:id/:subscribable_type/:subscribable_id/unsubscribeto unsubscribe from a resource. !9325 - Labels filter on
GET /projects/:id/issuesandGET /issuesnow matches only issues containing all labels (i.e.: Logical AND, not OR) !8849 - Renamed param
branch_nametobranchon the following endpoints !8936POST /projects/:id/repository/branchesPOST /projects/:id/repository/commitsPOST/PUT/DELETE :id/repository/files
- Renamed the
merge_when_build_succeedsparameter tomerge_when_pipeline_succeedson the following endpoints: !9335PUT /projects/:id/merge_requests/:merge_request_id/mergePOST /projects/:id/merge_requests/:merge_request_id/cancel_merge_when_pipeline_succeedsPOST /projectsPOST /projects/user/:user_idPUT /projects/:id
- Renamed
branch_nametobranchonDELETE /projects/:id/repository/branches/:branchresponse !8936 - Remove
publicparam from create and edit actions of projects !8736 - Remove
subscribedfield from responses returning list of issues or merge requests. Fetch individual issues or merge requests to obtain the value ofsubscribed!9661 - Use
visibilityas string parameter everywhere !9337 - Notes do not return deprecated field
upvoteanddownvote!9384 - Return HTTP status code
400for all validation errors when creating or updating a member instead of sometimes422error. !9523 - Remove
GET /groups/owned. UseGET /groups?owned=trueinstead !9505 - Return 202 with JSON body on async removals on V4 API (
DELETE /projects/:id/repository/merged_branchesandDELETE /projects/:id) !9449 -
GET /projects/:id/milestones?iid[]=x&iid[]=yarray filter has been renamed toiids!9096 - Return basic info about pipeline in
GET /projects/:id/pipelines!8875 - Renamed all
buildreferences tojob!9463 - Drop
GET /projects/:id/repository/commits/:sha/jobs!9463 - Rename Build Triggers to be Pipeline Triggers API !9713
-
POST /projects/:id/trigger/buildstoPOST /projects/:id/trigger/pipeline - Require description when creating a new trigger
POST /projects/:id/triggers
-
- Simplify project payload exposed on Environment endpoints !9675
- API uses merge request
IIDs (internal ID, as in the web UI) rather thanIDs. This affects the merge requests, award emoji, todos, and time tracking APIs. !9530 - API uses issue
IIDs (internal ID, as in the web UI) rather thanIDs. This affects the issues, award emoji, todos, and time tracking APIs. !9530 - Change initial page from
0to1onGET /projects/:id/repository/commits(like on the rest of the API) !9679 - Return correct
Linkheader data forGET /projects/:id/repository/commits!9679 - Update endpoints for repository files !9637
- Moved
GET /projects/:id/repository/files?file_path=:file_pathtoGET /projects/:id/repository/files/:file_path(:file_pathshould be URL-encoded) -
GET /projects/:id/repository/blobs/:shanow returns JSON attributes for the blob identified by:sha, instead of finding the commit identified by:shaand returning the raw content of the blob in that commit identified by the required?filepath=:filepath - Moved
GET /projects/:id/repository/commits/:sha/blob?file_path=:file_pathandGET /projects/:id/repository/blobs/:sha?file_path=:file_pathtoGET /projects/:id/repository/files/:file_path/raw?ref=:sha -
GET /projects/:id/repository/treeparameterref_namehas been renamed toreffor consistency
- Moved
-
confirmparameter forPOST /usershas been deprecated in favor ofskip_confirmationparameter