Class: SendGridWebApi::SubUserModules::Management
Instance Attribute Summary
Attributes inherited from Base
#api_key
Instance Method Summary
collapse
#base_url
#apps, #auth, #bounces, #event_notification, #iframe, #invalid_emails, #ip_management, #limits, #management, #monitor_records, #parse_email, #spam, #stats, #unsubscribes, #white_label
Methods inherited from Base
#builder_options, #initialize, #make_request_url, #query_api, #query_delete_api, #query_patch_api, #query_post_api, #query_post_json_api, #session, #to_query
Instance Method Details
#add(options = {}) ⇒ Object
9
10
11
12
|
# File 'lib/sub_user/management.rb', line 9
def add options = {}
management_add_url = "apiv2/customer.add.json"
query_api(management_add_url, options)
end
|
#disable(options = {}) ⇒ Object
19
20
21
22
|
# File 'lib/sub_user/management.rb', line 19
def disable options = {}
management_disable_url = "apiv2/customer.disable.json"
query_api(management_disable_url, options)
end
|
#enable(options = {}) ⇒ Object
14
15
16
17
|
# File 'lib/sub_user/management.rb', line 14
def enable options = {}
management_enable_url = "apiv2/customer.enable.json"
query_api(management_enable_url, options)
end
|
#get(options = {}) ⇒ Object
3
4
5
6
7
|
# File 'lib/sub_user/management.rb', line 3
def get options = {}
options.merge!({:task => "get"}) unless options[:task]
management_get_url = "apiv2/customer.profile.json"
query_api(management_get_url, options)
end
|
#update(options = {}) ⇒ Object
34
35
36
37
38
|
# File 'lib/sub_user/management.rb', line 34
def update options = {}
options.merge!(:task => "set") unless options[:task]
management_update_url = "apiv2/customer.profile.json"
query_api(management_update_url, options)
end
|
#update_email(options = {}) ⇒ Object
51
52
53
54
55
|
# File 'lib/sub_user/management.rb', line 51
def update_email options = {}
options.merge!({:task => "setEmail"}) unless options[:task]
management_update_url = "apiv2/customer.profile.json"
query_api(management_update_url, options)
end
|
#update_password(options = {}) ⇒ Object
40
41
42
43
|
# File 'lib/sub_user/management.rb', line 40
def update_password options = {}
management_set_password_url = "apiv2/customer.password.json"
query_api(management_set_password_url, options)
end
|
#update_username(options = {}) ⇒ Object
45
46
47
48
49
|
# File 'lib/sub_user/management.rb', line 45
def update_username options = {}
options.merge!({:task => "setUsername"}) unless options[:task]
management_update_url = "apiv2/customer.profile.json"
query_api(management_update_url, options)
end
|
#website_disable(options = {}) ⇒ Object
29
30
31
32
|
# File 'lib/sub_user/management.rb', line 29
def website_disable options = {}
management_website_disable_url = "apiv2/customer.website_disable.json"
query_api(management_website_disable_url, options)
end
|
#website_enable(options = {}) ⇒ Object
24
25
26
27
|
# File 'lib/sub_user/management.rb', line 24
def website_enable options = {}
management_website_enable_url = "apiv2/customer.website_enable.json"
query_api(management_website_enable_url, options)
end
|