@caido/server-auth
v0.2.0
Published
Authenticate with a Caido instance
Downloads
210
Keywords
Readme
👋 Server Auth
Authenticate with a Caido instance using device code flow.
import { CaidoAuth, BrowserApprover } from "@caido/server-auth";
const auth = new CaidoAuth(
"http://localhost:8080",
new BrowserApprover((request) => {
console.log(`Visit ${request.verificationUrl}`);
console.log(`Enter code: ${request.userCode}`);
})
);
const token = await auth.startAuthenticationFlow();
console.log("Access token:", token.accessToken);Examples
See the examples directory for complete working examples:
- Browser Authentication - Manual approval via browser
- PAT Authentication - Automated approval using Personal Access Token
💚 Community
Come join our Discord community and connect with other Caido users! We'd love to have you as part of the conversation and help with any questions you may have.
