Code Monkey home page Code Monkey logo

iterable-old's Introduction

Implementation of the Iterable API

Install

npm install node-iterable

Example

var Iterable = require('node-iterable');

var client = new Iterable({
	apiKey: '<iterable api key>'
});

return client.lists().get()
.then(function(lists){
	console.log(lists.lists);
}, function(err){
	console.log(err);
});

Resources

All resources are taken from those available in the Iterable API documentation. Resources are addressable by calling:

iterableInstance[<resource name>]()[<resource action>]({
	// optional data passed to resource
});

// e.g. to get lists:
iterableInstace.lists().get()
.then(function(data){
	// data response
});

// e.g. bulk update users
iterableInstace.users().bulkUpdate({
	users: {
		email: '[email protected]',
		dataFields: {
			// some data fields
		},
		userId: "someUserId"
	}
});

Actions and resources are as follows:

lists
	GET -  /
	POST - /lists/subscribe
	POST - /lists/unsubscribe
events
	POST - /events/trackConversion
	POST - /events/trackPushOpen
	POST - /events/track
users
	POST - /users/delete
	POST - /users/get
	POST - /users/updateEmail
	POST - /users/bulkUpdate
	POST - /users/registerDeviceToken
	POST - /users/updateSubscriptions
	GET  - /users/getByEmail
	GET  - /users/getFields
	POST - /users/update
	GET  - /users/getSentMessages
	POST - /users/disableDevice
push
	POST - /push/target
campaigns
	GET  - /
	POST - /campaigns/create
	POST - /campaigns/create
commerce
	POST - /commerce/trackPurchase
	POST - /commerce/updateCart
email
	GET  - /email/viewInBrowser
	POST - /email/target
workflows
	POST - /workflows/triggerWorkflow

iterable-old's People

Contributors

seanmcgary avatar

Watchers

Oleg Desantis avatar James Cloos avatar Guillaume avatar Dan Purdy avatar  avatar Matthew Butler avatar John Veronelli 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.