GithubHelp home page GithubHelp logo

tap-persistiq's Introduction

tap-persistiq

This is a Singer tap that produces JSON-formatted data following the Singer spec.

This tap:

Streams

users

leads

campaigns

Authentication

Quick Start

1. Install

Clone this repository, and then install using setup. py. We recommend using a virtualenv:

    > virtualenv -p python3 venv
    > source venv/bin/activate
    > python setup.py install
    OR
    > cd .../tap-persistiq
    > pip install .

or alternatively:

    > virtualenv -p python3 venv
    > source venv/bin/activate
    > pip install git+https://github.com/NickLeoMartin/tap-persistiq#egg=tap-persistiq

2. Dependent libraries

The following dependent libraries were installed.

    > pip install singer-python
    > pip install singer-tools
    > pip install target-stitch
    > pip install target-json

3. Create your tap's config.json file.

    {
        "api_key": "YOUR_PERSISTIQ_API_KEY",
        "start_date": "2019-01-01T00:00:00Z",
        "user_agent": "tap-persistiq <api_user_email@your_company.com>"
    }

Optionally, also create a state.json file. currently_syncing is an optional attribute used for identifying the last object to be synced in case the job is interrupted mid-stream. The next run would begin where the last job left off.

    {
        "currently_syncing": "leads",
        "bookmarks": {
            "users": "2019-09-27T22:34:39.000000Z",
            "companies": "2019-09-28T18:23:53Z"
        }
    }

4. Run the Tap in Discovery Mode

This creates a catalog. json for selecting objects/fields to integrate:

    tap-persistiq --config config.json --discover > catalog.json

See the Singer docs on discovery mode here.

5. Run the Tap in Sync Mode (with catalog) and write out to state file

For Sync mode:

    > tap-persistiq --config tap_config.json --catalog catalog.json > state.json
    > tail -1 state.json > state.json.tmp && mv state.json.tmp state.json

To load to json files to verify outputs:

    > tap-persistiq --config tap_config.json --catalog catalog.json | target-json > state.json
    > tail -1 state.json > state.json.tmp && mv state.json.tmp state.json

To pseudo-load to Stitch Import API with dry run:

    > tap-persistiq --config tap_config.json --catalog catalog.json | target-stitch --config target_config.json --dry-run > state.json
    > tail -1 state.json > state.json.tmp && mv state.json.tmp state.json

tap-persistiq's People

Contributors

nickleomartin avatar

Watchers

James Cloos avatar  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.