Giter Club home page Giter Club logo

socketlabs's Introduction

This is a project to retrieve email status information using the SocketLabs API.

For examples from SocketLabs themselves, refer to their github repo: https://github.com/socketlabs/

------------------------------

To install this website and start importing your own SocketLabs reports:
    Download and save the socketlabs_scraper.make file
        $ wget https://raw.github.com/cayala09/SocketLabs/master/socketlabs_scraper.make
    
    Use drush to download Drupal and necessary modules
        $ drush make socketlabs_scraper.make /path/to/install/drupal
    
    Upon beginning the Drupal installation, choose the profile "SocketLabs Email Tracker"
    Complete the installation as normal, and the feature will automatically be installed and active

------------------------------

Set up for the feeds:
	Upon installation, tabs will appear at the top of the home page. Each of these tabs
	refers to different feeds, or different API calls. You can click on a tab, click import,
	and enter the URL required for the API call. The format for the URL should be something
	like: https://username:[email protected]/...
	You can refer to https://www.socketlabs.com/od/api for the API reference.

------------------------------

Currently the importing/expiring of nodes requires a few changes to the Feeds module.
These changes are all minor, mostly they consist of adding an option to import/expire 
every 5 minutes. The changes needed are as follows:

Changes to Feeds module:

  In FeedsImporter.inc (includes folder)
    Line 93 changed to: $job[‘period’]=$this->processor->expiryTime();
    Line 242 changed expire_period to 300
    Line 279 added 300 to array

  In FeedsNodeProcessor.inc (plugins folder)
    Line 152 added 300 to array

------------------------------

The crontab is used, in this case, to make cron run every 6 minutes. When cron runs, nodes will be deleted if they have expired and import new nodes if it is time.
Crontab Configuration:

cd to /sites/all/modules
crontab -e
add following line: */6 * * * * wget -O - -q http://yoursitename:8080/cron.php

If this does not work due to permissions (check recent log messages to confirm), go to the status report and look for the url for updating cron externally.
This will have a long token to append after the cron.php portion of the url used to authenticate your cron job.

socketlabs's People

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.