Skip to content
Snippets Groups Projects
Commit eaa99478 authored by Riyad Preukschas's avatar Riyad Preukschas
Browse files

Up API version to v3

parent 8f01190e
No related branches found
No related tags found
1 merge request!2330V4.0 API fixes
: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
@@ -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
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