class Synthetics::API::Label
This class makes requests to the labels section of the Synthetics
API
.
Attributes
label[R]
Public Class Methods
new(client, label)
click to toggle source
Calls superclass method
Synthetics::API::Base::new
# File lib/synthetics/api/label.rb, line 7 def initialize(client, label) super(client) @label = label end
Public Instance Methods
attach(monitor_uuid)
click to toggle source
# File lib/synthetics/api/label.rb, line 16 def attach(monitor_uuid) request( method: 'POST', path: "/monitors/#{monitor_uuid}/labels", body: label ) end
monitors()
click to toggle source
# File lib/synthetics/api/label.rb, line 12 def monitors request(method: 'GET', path: "/monitors/labels/#{label}") end
remove(monitor_uuid)
click to toggle source
# File lib/synthetics/api/label.rb, line 24 def remove(monitor_uuid) request( method: 'DELETE', path: "/monitors/#{monitor_uuid}/labels/#{label}" ) end