Class: Sms77::Resources::Contacts
- Inherits:
-
Sms77::Resource
- Object
- Sms77::Resource
- Sms77::Resources::Contacts
- Defined in:
- lib/sms77/resources/contacts.rb
Constant Summary
Constants inherited from Sms77::Resource
Instance Attribute Summary
Attributes inherited from Sms77::Resource
#api_key, #builder, #conn, #endpoint, #http_methods, #request_methods, #sent_with
Instance Method Summary collapse
-
#delete(params) ⇒ String, Hash
Delete an account with given ID read more: www.sms77.io/en/docs/gateway/http-api/contacts/#delete-contacts.
-
#read(params = {}) ⇒ String, Hash
Retrieve contacts associated with the API key read more: www.sms77.io/en/docs/gateway/http-api/contacts/#read-contacts.
-
#write(params) ⇒ String, Hash
Create or update a contact read more: www.sms77.io/en/docs/gateway/http-api/contacts/#create-and-edit-contacts.
Methods inherited from Sms77::Resource
get_endpoint, get_http_methods, #initialize
Constructor Details
This class inherits a constructor from Sms77::Resource
Instance Method Details
#delete(params) ⇒ String, Hash
Delete an account with given ID read more: www.sms77.io/en/docs/gateway/http-api/contacts/#delete-contacts
27 28 29 |
# File 'lib/sms77/resources/contacts.rb', line 27 def delete(params) request({}, params.merge({ :action => Sms77::Contacts::Action::DEL })) end |
#read(params = {}) ⇒ String, Hash
Retrieve contacts associated with the API key read more: www.sms77.io/en/docs/gateway/http-api/contacts/#read-contacts
19 20 21 |
# File 'lib/sms77/resources/contacts.rb', line 19 def read(params = {}) request(params.merge({ :action => Sms77::Contacts::Action::READ })) end |
#write(params) ⇒ String, Hash
Create or update a contact read more: www.sms77.io/en/docs/gateway/http-api/contacts/#create-and-edit-contacts
35 36 37 |
# File 'lib/sms77/resources/contacts.rb', line 35 def write(params) request({}, params.merge({ :action => Sms77::Contacts::Action::WRITE })) end |