Skip to content
/ pocus Public

Unofficial Ruby API client for iContact API (f.k.a. Vocus), inspired by Active Resource.

License

Notifications You must be signed in to change notification settings

varyonic/pocus

Folders and files

NameName
Last commit message
Last commit date

Latest commit

1894f9b · Apr 5, 2020

History

93 Commits
Dec 13, 2019
Jan 27, 2020
Jan 28, 2020
Jan 17, 2019
Dec 17, 2019
Dec 17, 2019
May 15, 2016
Dec 17, 2019
May 26, 2016
May 15, 2016
Dec 17, 2019
Jan 17, 2019
Apr 5, 2020

Repository files navigation

Pocus

Gem Version Code Climate GPA Travis CI Status

Unofficial Ruby API client for iContact API (f.k.a. Vocus), inspired by Active Resource.

Installation

Add to your application's Gemfile:

gem 'pocus'

And then execute:

$ bundle

Requirements

iContact account, AppID and credentials, see the iContact API Getting Started Guide.

Usage

Configure a connection and connect to the account:

    credentials = { host: 'app.icontact.com', app_id: a, username: u, password: p }
    session = Pocus::Session.new(credentials)
    session.logger = Rails.logger
	account = Pocus::Account.new(session: session, account_id: account_id)

Navigate and update entities:

	folder = acount.clientfolders.find(folder_id)
	folder.contacts.create(contacts_data)

See the specs for sample code.

Tests

To run the tests you will need your own iContact account with a test folder (name: 'My First List'). Set the following environment variables:

POCUS_APP_ID=0b34...b478c
[email protected]
POCUS_PASSWORD=...
POCUS_TEST_ACCOUNT=99...99
POCUS_TEST_CLIENT_FOLDER=9...9

To test, run:

bundle exec rake

Contributions

Read CONTRIBUTING for details.

History

Read the CHANGELOG for details.

License

The gem is available as open source under the terms of the MIT License.

Read the LICENSE for details.

Copyright (c) 2016-2019 Varyonic.

About

Unofficial Ruby API client for iContact API (f.k.a. Vocus), inspired by Active Resource.

Topics

Resources

License

Code of conduct

Stars

Watchers

Forks

Packages

No packages published