A node.js module, which provides a simple wrapper for the Eloqua API.
Install using npm:
$ npm install eloqua-sdk
// With ES5
var EloquaApi = require('eloqua-sdk');
var eloqua_config = {
sitename: '[[Your Sitename]]',
username: '[[Your Username]]',
password: '[[Your Password]]'
};
var eloqua = new EloquaApi(eloqua_config);
// With ES6
import EloquaApi from 'eloqua-sdk';
const eloqua_config = {
sitename: '[[Your Sitename]]',
username: '[[Your Username]]',
password: '[[Your Password]]'
};
const eloqua = new EloquaApi(eloqua_config);
// With ES7
import EloquaApi from 'eloqua-sdk';
const eloqua_config = {
sitename: '[[Your Sitename]]',
username: '[[Your Username]]',
password: '[[Your Password]]'
};
const eloqua = new EloquaApi(eloqua_config);
// ES5
eloqua.assets.campaigns.get()
.then(function(results) {
console.log('Campaign Name: ' + results.data.elements[0].name);
})
.catch(function(err) {
console.error(err);
});
// ES6
eloqua.assets.campaigns.get()
.then(results => {
console.log(`Campaign Name: ${results.data.elements[0].name}`);
})
.catch(err => {
console.error(err);
});
// ES7
async function getCampaigns() {
try {
const results = await eloqua.assets.campaigns.get();
console.log(`Campaign Name: ${results.data.elements[0].name}`);
} catch(err) {
console.error(err);
}
}
getCampaigns();
Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.
We use SemVer for versioning. For the versions available, see the tags on this repository.
- Jeff Baldwin - Initial work - JeffBaldwinJr
See also the list of contributors who participated in this project.
This project is licensed under the MIT License - see the LICENSE.md file for details