Optionaloptions: SalesforceOAuth2LoginOptionsOptions for the login flow
The authentication result
const loginFlow = await sfdx.deviceLogin();
console.log(`Please login to Salesforce using the code ${loginFlow.userCode} on ${loginFlow.verificationUrl}`);
// Ser the openVerificationUrl option to false to prevent opening the verification URL in the browser
const authResult = await loginFlow.awaitDeviceApproval({ openVerificationUrl: true });
console.log(`Successfully logged in to Salesforce as ${authResult.username}`);
Login to Salesforce using the OAuth2 Device Flow. In this flow a user code is displayed to the user that must be entered on the device login page.
If o options are specified the default login URL is used defaultLoginUrl.