Note: This release is in preview. Features described here don’t become generally available until the latest general availability date that Salesforce announces for this release. Before then, and where features are noted as beta, pilot, or developer preview, we can’t guarantee general availability within any particular time frame or at all. Make your purchase decisions only on the basis of generally available products and features.

Authorize an Org Using Its SFDX Authorization URL

Use an org's Salesforce DX (SFDX) authorization URL to authorize an org in continuous integration (CI) environments, which are fully automated and don’t support the human interactivity of logging into a browser.
  1. Open a terminal (macOS and Linux) or command prompt (Windows) on the computer where you’ve already authorized the org using a Web browser.
  2. Get your org’s SFDX authorization URL and store it in a file by running this command.
    1sf org auth show-sfdx-auth-url --target-org my-org --json > authFile.json
    The JSON output includes a key called sfdxAuthUrl, whose value is the org’s SFDX authorization URL.
  3. In your CI environment, authorize the org by referencing the authFile.json file with this command.
    1sf org login sfdx-url --sfdx-url-file authFile.json
For more information and examples, see the reference about the org login sfdx-url command in the Salesforce CLI Command Reference.