UNPKG

@salesforce/core

Version:

Core libraries to interact with SFDX projects, orgs, and APIs.

44 lines (43 loc) 1.83 kB
import { Duration } from '@salesforce/kit'; import { Org } from './org'; import { AuthInfo, AuthFields } from './authInfo'; import { ScratchOrgInfo } from './scratchOrgInfoApi'; export declare const DEFAULT_STREAM_TIMEOUT_MINUTES = 6; export interface ScratchOrgCreateResult { username?: string; scratchOrgInfo?: ScratchOrgInfo; authInfo?: AuthInfo; authFields?: AuthFields; warnings: string[]; } /** * interface ScratchOrgCreateOptions * * @param hubOrg the environment hub org * @param connectedAppConsumerKey The connected app consumer key. * @param durationDays duration of the scratch org (in days) (default:1, min:1, max:30) * @param nonamespace create the scratch org with no namespace * @param noancestors do not include second-generation package ancestors in the scratch org * @param wait the streaming client socket timeout (in minutes) must be an instance of the Duration utility class (default:6, min:2) * @param retry number of scratch org auth retries after scratch org is successfully signed up (default:0, min:0, max:10) * @param apiversion target server instance API version * @param definitionjson org definition in JSON format * @param definitionfile path to an org definition file * @param orgConfig overrides definitionjson * @param clientSecret OAuth client secret of personal connected app */ export interface ScratchOrgCreateOptions { hubOrg: Org; connectedAppConsumerKey?: string; durationDays?: number; nonamespace?: boolean; noancestors?: boolean; wait?: Duration; retry?: number; apiversion?: string; definitionjson?: string; definitionfile?: string; orgConfig?: Record<string, unknown>; clientSecret?: string; } export declare const scratchOrgCreate: (options: ScratchOrgCreateOptions) => Promise<ScratchOrgCreateResult>;