Create a ticket
Sign in Sign up
Locker support Locker support
Results

No results found.

Home Locker Secrets Manager Developer tools Secrets - SDK NodeJS Usages Get environments
Vietnamese English
Get environments

Methods:

  • listEnvironments: list all environments

listEnvironments: () => Promise<Environment[]>

  • listEnvironmentsSync: list all environments but synchronized

listEnvironmentsSync: () => Environment[]

  • getEnvironment: get an environment by name

getEnvironment: (name: string) => Promise<Environment | undefined>

  • getEnvironmentSync: get an environment but synchronized

getEnvironmentSync: () => Environment | undefined

Example

// List environments
const environments = await locker.listEnvironments()
// or
const environments = locker.listEnvironmentsSync()

// Get an environment object by name
const environment = await locker.getEnvironment('prod')
// or
const environment = locker.getEnvironmentSync('prod')
 
Was this page helpful?
No
Yes
Join Our Community