Class: Raven::Domain

Inherits:
Object
  • Object
show all
Defined in:
lib/rb_raven_api/domain.rb

Class Method Summary collapse

Class Method Details

.add(domain, engine_id = '1,2,3', cstm = {}) ⇒ Object

This request will add the domain provided.

Parameters:

  • domain (String)

    Required The domain name you want to add. “www.” prefixes are ignored for purposes of matching ranks, but will be stored as part of the domain name for future requests.

  • engine_id (String) (defaults to: '1,2,3')

    Optional Comma separate list of search engine ids that you want to track for this domain. Defaults to ‘1,2,3’ which is Google, Yahoo! and Bing



22
23
24
# File 'lib/rb_raven_api/domain.rb', line 22

def self.add domain, engine_id = '1,2,3', cstm = {}
  Raven.http.get '', { method: 'add_domain', domain: domain, engine_id: engine_id }.merge(cstm)
end

.all(cstm = {}) ⇒ Array

Your account domains.

Returns:

  • (Array)

    Domains.



11
12
13
# File 'lib/rb_raven_api/domain.rb', line 11

def self.all cstm = {}
  Raven.http.get '', { method: 'domains' }.merge(cstm)
end

.info(domain, cstm = {}) ⇒ Object

This request will return the search engines for the domain provided.

Parameters:

  • domain (String)

    Required The domain name you want info for. _Must match exactly_



52
53
54
# File 'lib/rb_raven_api/domain.rb', line 52

def self.info domain, cstm = {}
  Raven.http.get '', { method: 'domain_info', domain: domain }.merge(cstm)
end

.keywords(domain, cstm = {}) ⇒ Object

This request will return the available keywords for the domain provided.

Parameters:

  • domain (String)

    Required The domain name you want results for. _Must match exactly_



32
33
34
# File 'lib/rb_raven_api/domain.rb', line 32

def self.keywords domain, cstm = {}
  Raven.http.get '', { method: 'keywords', domain: domain }.merge(cstm)
end

.keywords_with_tags(domain, cstm = {}) ⇒ Object

This request will return the available keywords for the domain provided.

Parameters:

  • domain (String)

    Required The domain name you want results for. _Must match exactly_



42
43
44
# File 'lib/rb_raven_api/domain.rb', line 42

def self.keywords_with_tags domain, cstm = {}
  Raven.http.get '', { method: 'keywords_tags', domain: domain }.merge(cstm)
end