module Gitlab::Client::SystemHooks

def add_hook(url, options = {})

Returns:
  • (Gitlab::ObjectifiedHash) -

Options Hash: (**options)
  • :enable_ssl_verification (boolean) -- `false` will cause Gitlab to ignore invalid/unsigned certificate errors (default is `true`)
  • :token (String) -- A secret token for Gitlab to send in the `X-Gitlab-Token` header for authentication.

Parameters:
  • options (Hash) -- Additional options, as allowed by Gitlab API, including but not limited to:
  • url (String) -- The hook URL.
def add_hook(url, options = {})
  post('/hooks', body: options.merge(url: url))
end

def delete_hook(id)

Returns:
  • (Gitlab::ObjectifiedHash) -

Parameters:
  • id (Integer) -- The ID of a system hook.
def delete_hook(id)
  delete("/hooks/#{id}")
end

def hook(id)

Returns:
  • (Array) -

Parameters:
  • id (Integer) -- The ID of a system hook.
def hook(id)
  get("/hooks/#{id}")
end

def hooks(options = {})

Returns:
  • (Array) -

Options Hash: (**options)
  • :per_page (Integer) -- The number of results per page.
  • :page (Integer) -- The page number.

Parameters:
  • options (Hash) -- A customizable set of options.
def hooks(options = {})
  get('/hooks', query: options)
end