# passport-eloqua

> Eloqua authentication strategy for Passport

Latest version **0.0.1** (published 2014-08-23) · 0 weekly downloads

## Install

```sh
npm install passport-eloqua
pnpm add passport-eloqua
yarn add passport-eloqua
bun add passport-eloqua
```

## Health

**Score 10/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; low quality score; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.1 |
| Published | 2014-08-23 |
| First published | 2014-08-23 |
| Weekly downloads | 0 |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >= 0.4.0 |
| Dependencies | 2 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Maintainers | watsoncj |

## Links

- npm: https://www.npmjs.com/package/passport-eloqua
- Repository: https://github.com/watsoncj/passport-eloqua
- Issues: https://github.com/watsoncj/passport-eloqua/issues
- npm.io page: https://npm.io/package/passport-eloqua

## Dependencies (2)

- [pkginfo](https://npm.io/package/pkginfo.md) 0.2.x
- [passport-oauth](https://npm.io/package/passport-oauth.md) 0.1.x

## Recent versions

- 0.0.1 (latest) — 2014-08-23

## README

# Passport-eloqua

[Passport](https://github.com/jaredhanson/passport) strategy for authenticating
with [Eloqua](http://eloqua.com/) using the OAuth 2.0 API.

## Install

    $ npm install passport-eloqua

## Usage

#### Configure Strategy

    EloquaStrategy = require('passport-eloqua').EloquaStrategy;

    passport.use(new EloquaStrategy({
        clientID: ELOQUA_CLIENT_ID,
        clientSecret: ELOQUA_CLIENT_SECRET,
        callbackURL: "http://example.com/auth/eloqua/callback"
      },
      function(accessToken, refreshToken, profile, done) {
        User.findOrCreate({ eloquaId: profile.id }, function (err, user) {
          return done(err, user);
        });
      }
    ));

#### Authenticate Requests

Use `passport.authenticate()`, specifying the `'eloqua'` strategy, to 
authenticate requests.

For example, as route middleware in an [Express](http://expressjs.com/)
application:

    app.get('/auth/eloqua',
      passport.authenticate('eloqua'));

    app.get('/auth/eloqua/callback',
      passport.authenticate('eloqua', { failureRedirect: '/login' }),
      function(req, res) {
        // Successful authentication, redirect home.
        res.redirect('/');
      });

## Thanks

  - [Jared Hanson](http://github.com/jaredhanson)
  - [dreadjr](http://github.com/dreadjr)

## License

  [The MIT License](http://opensource.org/licenses/MIT)

  Copyright (c) 2011-2014 Jared Hanson <[http://jaredhanson.net/](http://jaredhanson.net/)>, Et al.

---
_Source: https://npm.io/package/passport-eloqua · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
