Node.js library for OAuth2 authentication with Salesforce Marketing Cloud (formerly ExactTarget) REST and SOAP APIs. Version 3.3.0 targets Node >= 4, uses request package for HTTP, and is ESM-only with TypeScript declarations. It simplifies obtaining access tokens using client credentials or refresh tokens. Compared to manual OAuth2 flows, it handles token caching, refresh, and error handling. The library is actively maintained by Salesforce but has limited updates for newer Node versions.
npm install fuel-authNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows ES module import, instantiation of AuthClient with credentials, and obtaining an access token.
Migrate to a modern HTTP client (e.g., node-fetch, axios) via a wrapper or fork.
Use import syntax and ensure package.json has 'type': 'module' or use .mjs extension.
Update authUrl to 'https://mc.exacttargetapis.com/v1/requestToken' or the correct v2 endpoint.
Implement custom cache adapter via the 'cache' option or use a shared cache like Redis.
Switch to ES module import syntax or downgrade to v2.x.
Use default import: import AuthClient from 'fuel-auth'
Update authUrl to the correct endpoint for your region.
Verify credentials in Salesforce Marketing Cloud setup.