Skip to content
This repository has been archived by the owner on Mar 1, 2020. It is now read-only.
stevecreedon edited this page Apr 14, 2016 · 16 revisions

Resolver SEO is a gem that combines data from:

  1. Models from the webapp
  2. Data from Google Analytics
  3. Data from scraping Google (4. Data from Webmaster tools - TBA)

The data is stored in Mongo using Mongoid. Data that varies over time - Case File Counts, Landing Page Counts are stored in monthly records. Scrapes of Google have a created_at timestamp so are a snapshot of the time they are created.

Import Models from the webapp with the rake task:

This will import Company, Service and ServiceType models PLUS month on month counts of case files for each service. On a complaint server:

bundle exec rake resolver:seo:export_resolver_models

Import Landing Page Data from GA for a month or a 'year of months' with the rake task:

This will import Landing page data (entrances, bounce, new users etc) for the company and the company-contact-details page. Data is matched to the Company model using the slug. On a crichton server:

#for a year and month
bundle exec rake ga_company_pages[2016,4]
 
#for every month in a year
bundle exec rake ga_company_pages_year[2016]

Scrape data from Google (very slowly)

This will scrape google substituting NAME for the company name in each search. It will extract details of the first page enabling us to understand where we are and who is above us. On a Crichton server

bundle exec rake "scrape_google[NAME complaints]"

(NOTE: The "" around the rake command so we can have white space in the arguments)