Class: SendGrid4r::CLI::Whitelabel::Ip

Inherits:
SgThor
  • Object
show all
Defined in:
lib/sendgrid4r/cli/whitelabel/ip.rb

Overview

SendGrid Web API v3 Whitelabel Ip

Instance Method Summary collapse

Methods inherited from SgThor

#initialize

Constructor Details

This class inherits a constructor from SendGrid4r::CLI::SgThor

Instance Method Details

#createObject



21
22
23
24
25
# File 'lib/sendgrid4r/cli/whitelabel/ip.rb', line 21

def create
  puts @client.post_wl_ip(parameterise(options))
rescue RestClient::ExceptionWithResponse => e
  puts e.inspect
end

#deleteObject



37
38
39
40
41
# File 'lib/sendgrid4r/cli/whitelabel/ip.rb', line 37

def delete
  puts @client.delete_wl_ip(parameterise(options))
rescue RestClient::ExceptionWithResponse => e
  puts e.inspect
end

#getObject



29
30
31
32
33
# File 'lib/sendgrid4r/cli/whitelabel/ip.rb', line 29

def get
  puts @client.get_wl_ip(parameterise(options))
rescue RestClient::ExceptionWithResponse => e
  puts e.inspect
end

#listObject



11
12
13
14
15
# File 'lib/sendgrid4r/cli/whitelabel/ip.rb', line 11

def list
  puts @client.get_wl_ips(parameterise(options))
rescue RestClient::ExceptionWithResponse => e
  puts e.inspect
end

#validateObject



45
46
47
48
49
# File 'lib/sendgrid4r/cli/whitelabel/ip.rb', line 45

def validate
  puts @client.validate_wl_ip(parameterise(options))
rescue RestClient::ExceptionWithResponse => e
  puts e.inspect
end