module HoverflyAPI

Public Instance Methods

clear_cached_data() click to toggle source
# File lib/endpoints.rb, line 60
def clear_cached_data
  HoverflyAPI.delete('/api/v2/cache').response.body
end
get_cached_data() click to toggle source
# File lib/endpoints.rb, line 56
def get_cached_data
  HoverflyAPI.get('/api/v2/cache').response.body
end
get_config_info() click to toggle source
# File lib/endpoints.rb, line 16
def get_config_info
  HoverflyAPI.get('/api/v2/hoverfly').response.body
end
get_current_destination() click to toggle source
# File lib/endpoints.rb, line 20
def get_current_destination
  HoverflyAPI.get('/api/v2/hoverfly/destination').response.body
end
get_current_middleware() click to toggle source
# File lib/endpoints.rb, line 28
def get_current_middleware
  HoverflyAPI.get('/api/v2/hoverfly/middleware').response.body
end
get_current_mode() click to toggle source
# File lib/endpoints.rb, line 36
def get_current_mode
  HoverflyAPI.get('/api/v2/hoverfly/mode').response.body
end
get_current_simulation_schema() click to toggle source
# File lib/endpoints.rb, line 12
def get_current_simulation_schema
  HoverflyAPI.get('/api/v2/simulation/schema').response.body
end
get_current_simulations() click to toggle source
# File lib/endpoints.rb, line 4
def get_current_simulations
  HoverflyAPI.get('/api/v2/simulation').response.body
end
get_logs() click to toggle source
# File lib/endpoints.rb, line 64
def get_logs
  HoverflyAPI.get('/api/v2/logs').response.body
end
get_upstream_proxy() click to toggle source
# File lib/endpoints.rb, line 52
def get_upstream_proxy
  HoverflyAPI.get('/api/v2/hoverfly/upstream-proxy').response.body
end
get_usage() click to toggle source
# File lib/endpoints.rb, line 44
def get_usage
  HoverflyAPI.get('/api/v2/hoverfly/usage').response.body
end
get_version() click to toggle source
# File lib/endpoints.rb, line 48
def get_version
  HoverflyAPI.get('/api/v2/hoverfly/version').response.body
end
update_destination(destination) click to toggle source
# File lib/endpoints.rb, line 24
def update_destination(destination)
  HoverflyAPI.put('/api/v2/hoverfly/destination', headers: { 'Content-Type' => 'application/json' }, body: { destination: destination }.to_json).response.body
end
update_middleware(middleware_request) click to toggle source
# File lib/endpoints.rb, line 32
def update_middleware(middleware_request)
  HoverflyAPI.put('/api/v2/hoverfly/middleware', headers: { 'Content-Type' => 'application/json' }, body: middleware_request.to_json).response.body
end
update_mode(mode) click to toggle source
# File lib/endpoints.rb, line 40
def update_mode(mode)
  HoverflyAPI.put('/api/v2/hoverfly/mode', headers: { 'Content-Type' => 'application/json' }, body: { mode: mode }.to_json).response.body
end
update_simulations(simulation) click to toggle source
# File lib/endpoints.rb, line 8
def update_simulations(simulation)
  HoverflyAPI.put('/api/v2/simulation', headers: { 'Content-Type' => 'application/json' }, body: simulation).response.body
end