Add OAuth 1.0a signing to axios requests via interceptors. Current stable version is 0.4.1, updated occasionally. Supports HMAC-SHA1 and HMAC-SHA256 algorithms, auto body hash for POST/PUT, optional realm, callback, verifier, and token secret. Ships TypeScript types, but requires polyfills for buffer and crypto in browsers. Alternative to oauth-1.0a with tighter axios integration, but depends on axios >=0.21.0.
npm install axios-oauth-1.0aNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Creates an axios client with OAuth 1.0a interceptor using environment variables for credentials.
Configure resolve.fallback in webpack.config.js: { buffer: require.resolve('buffer/'), crypto: require.resolve('crypto-browserify') } and install packages: npm install buffer crypto-browserifySet includeBodyHash: true if you need body hash on all methods (e.g., PATCH).
Use algorithm: 'HMAC-SHA256'.
Pin to exact version or use lockfile. Check releases for breaking changes.
Add resolve.fallback for buffer and crypto in webpack config and install buffer and crypto-browserify packages.
Ensure you pass an axios instance created via axios.create() or axios for interceptors to be added.