Sha256: 28a4eb0437e4a2bb251710885f30b06ece4d7e2cfbd474683a621301e3cf79ad

Contents?: true

Size: 576 Bytes

Versions: 11

Compression:

Stored size: 576 Bytes

Contents

module SendGridWebApi::SubUserModules
  class Unsubscribe < SendGridWebApi::SubUser
    UNSUBSCRIBE_URL = "api/user.unsubscribes.json"
    
    def get options = {}
      options.merge!({:task => "get"}) unless options[:task]
      query_api(UNSUBSCRIBE_URL, options)
    end

    def add options = {}
      options.merge!({:task => "add"}) unless options[:task]
      query_api(UNSUBSCRIBE_URL, options)    
    end

  
    def delete options = {}
      options.merge!({:task => "delete"}) unless options[:task]
      query_api(UNSUBSCRIBE_URL, options)    
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
sendgrid_webapi-0.2.0 lib/sub_user/unsubscribes.rb
sendgrid_webapi-0.1.2 lib/sub_user/unsubscribes.rb
sendgrid_webapi-0.1.1 lib/sub_user/unsubscribes.rb
sendgrid_webapi-0.1.0 lib/sub_user/unsubscribes.rb
sendgrid_webapi-0.0.8 lib/sub_user/unsubscribes.rb
sendgrid_webapi-0.0.6 lib/sub_user/unsubscribes.rb
sendgrid_webapi-0.0.5 lib/sub_user/unsubscribes.rb
sendgrid_webapi-0.0.4 lib/sub_user/unsubscribes.rb
sendgrid_webapi-0.0.3 lib/sub_user/unsubscribes.rb
sendgrid_webapi-0.0.2 lib/sub_user/unsubscribes.rb
sendgrid_webapi-0.0.1 lib/sub_user/unsubscribes.rb