Arco CLI Auth

raw JSON →
1.0.3 verified Sat Apr 25 auth: no javascript

Auth module for Arco CLI, providing authentication functionality for Arco design system command-line tools. Version 1.0.3 is the current stable release with no known update cadence. It is a minimal package likely used internally within the Arco ecosystem, and not intended for general use. Differentiator: specific to Arco CLI workflows, not a general-purpose auth library.

error Error [ERR_REQUIRE_ESM]: require() of ES Module not supported
cause Using CommonJS require() on an ESM-only package.
fix
Change to import statement or set type: module in package.json.
error TypeError: auth is not a function
cause Incorrect import syntax, likely using named import when only default export exists.
fix
Use import auth from 'arco-cli-auth' instead of import { auth } from ....
gotcha Package is designed for internal Arco CLI use only. Public API may change without notice.
fix Do not depend on this package directly outside of Arco CLI.
deprecated The package has no recent updates; consider it unmaintained for external use.
fix Use a standard authentication library like OAuth2 client.
breaking Version 1.0.0 changed from CommonJS to ESM-only. Requiring via require() may fail.
fix Use import syntax or enable ESM in your project.
npm install arco-cli-auth
yarn add arco-cli-auth
pnpm add arco-cli-auth

Demonstrates how to authenticate and logout using arco-cli-auth, assuming OAuth2 flow with client ID and redirect URI.

import { login, logout } from 'arco-cli-auth';

async function main() {
  const token = await login({ clientId: 'my-app', redirectUri: 'http://localhost:3000/callback' });
  console.log('Token:', token);
  // Use token for API calls
  await logout(token);
}
main().catch(console.error);