diff options
author | Gauvain Pocentek <gauvain.pocentek@objectif-libre.com> | 2016-10-23 09:46:39 +0200 |
---|---|---|
committer | Sean McGivern <sean@gitlab.com> | 2016-11-01 10:41:39 +0000 |
commit | c85c146aa2042710caddc6666ce8f9e07b2fe5ca (patch) | |
tree | c091ac5ec84f1af498be9a1246ee0e2555fe1699 /lib/api/project_hooks.rb | |
parent | 266fcfb1935c8aa8c6ac3d2ae71530c441b08675 (diff) | |
download | gitlab-ce-c85c146aa2042710caddc6666ce8f9e07b2fe5ca.tar.gz |
Add support for token attr in project hooks API
The UI allows to define a token to validate payload on the target URL,
this patch adds the feature to the API.
Diffstat (limited to 'lib/api/project_hooks.rb')
-rw-r--r-- | lib/api/project_hooks.rb | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/api/project_hooks.rb b/lib/api/project_hooks.rb index 14f5be3b5f6..dd93a85dc54 100644 --- a/lib/api/project_hooks.rb +++ b/lib/api/project_hooks.rb @@ -47,7 +47,8 @@ module API :build_events, :pipeline_events, :wiki_page_events, - :enable_ssl_verification + :enable_ssl_verification, + :token ] @hook = user_project.hooks.new(attrs) @@ -82,7 +83,8 @@ module API :build_events, :pipeline_events, :wiki_page_events, - :enable_ssl_verification + :enable_ssl_verification, + :token ] if @hook.update_attributes attrs |