summaryrefslogtreecommitdiff
path: root/lib/api
diff options
context:
space:
mode:
authorGrzegorz Bizon <grzesiek.bizon@gmail.com>2018-08-21 11:12:23 +0200
committerGrzegorz Bizon <grzesiek.bizon@gmail.com>2018-08-21 11:12:23 +0200
commit6232c26ac7aa279f7082ceb04b16e42673196475 (patch)
tree04ec906c8f55528e4735be86de76da4f3c1fd520 /lib/api
parent00aa4d4c8c57a2f305070c2f9cb86fde6bc14285 (diff)
parentcc0bf2f6231a3c231450a7ef8f272de9f9591eaa (diff)
downloadgitlab-ce-6232c26ac7aa279f7082ceb04b16e42673196475.tar.gz
Merge branch 'master' into sh-add-object-storage-qa
* master: (31 commits)
Diffstat (limited to 'lib/api')
-rw-r--r--lib/api/events.rb5
-rw-r--r--lib/api/services.rb15
2 files changed, 5 insertions, 15 deletions
diff --git a/lib/api/events.rb b/lib/api/events.rb
index fc4ba5a3188..a415508a632 100644
--- a/lib/api/events.rb
+++ b/lib/api/events.rb
@@ -1,6 +1,7 @@
module API
class Events < Grape::API
include PaginationParams
+ include APIGuard
helpers do
params :event_filter_params do
@@ -24,6 +25,8 @@ module API
end
resource :events do
+ allow_access_with_scope :read_user, if: -> (request) { request.get? }
+
desc "List currently authenticated user's events" do
detail 'This feature was introduced in GitLab 9.3.'
success Entities::Event
@@ -46,6 +49,8 @@ module API
requires :id, type: String, desc: 'The ID or Username of the user'
end
resource :users do
+ allow_access_with_scope :read_user, if: -> (request) { request.get? }
+
desc 'Get the contribution events of a specified user' do
detail 'This feature was introduced in GitLab 8.13.'
success Entities::Event
diff --git a/lib/api/services.rb b/lib/api/services.rb
index 1f2bf546cd7..d1a5ee7db35 100644
--- a/lib/api/services.rb
+++ b/lib/api/services.rb
@@ -354,20 +354,6 @@ module API
desc: 'Flowdock token'
}
],
- 'gemnasium' => [
- {
- required: true,
- name: :api_key,
- type: String,
- desc: 'Your personal API key on gemnasium.com'
- },
- {
- required: true,
- name: :token,
- type: String,
- desc: "The project's slug on gemnasium.com"
- }
- ],
'hangouts-chat' => [
{
required: true,
@@ -695,7 +681,6 @@ module API
EmailsOnPushService,
ExternalWikiService,
FlowdockService,
- GemnasiumService,
HangoutsChatService,
HipchatService,
IrkerService,