published on Monday, Mar 9, 2026 by Pulumi
published on Monday, Mar 9, 2026 by Pulumi
Use this data source to access information about an Environment.
Using getEnvironment
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getEnvironment(args: GetEnvironmentArgs, opts?: InvokeOptions): Promise<GetEnvironmentResult>
function getEnvironmentOutput(args: GetEnvironmentOutputArgs, opts?: InvokeOptions): Output<GetEnvironmentResult>def get_environment(environment_id: Optional[int] = None,
name: Optional[str] = None,
project_id: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetEnvironmentResult
def get_environment_output(environment_id: Optional[pulumi.Input[int]] = None,
name: Optional[pulumi.Input[str]] = None,
project_id: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetEnvironmentResult]func LookupEnvironment(ctx *Context, args *LookupEnvironmentArgs, opts ...InvokeOption) (*LookupEnvironmentResult, error)
func LookupEnvironmentOutput(ctx *Context, args *LookupEnvironmentOutputArgs, opts ...InvokeOption) LookupEnvironmentResultOutput> Note: This function is named LookupEnvironment in the Go SDK.
public static class GetEnvironment
{
public static Task<GetEnvironmentResult> InvokeAsync(GetEnvironmentArgs args, InvokeOptions? opts = null)
public static Output<GetEnvironmentResult> Invoke(GetEnvironmentInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetEnvironmentResult> getEnvironment(GetEnvironmentArgs args, InvokeOptions options)
public static Output<GetEnvironmentResult> getEnvironment(GetEnvironmentArgs args, InvokeOptions options)
fn::invoke:
function: azuredevops:index/getEnvironment:getEnvironment
arguments:
# arguments dictionaryThe following arguments are supported:
- Project
Id string - The ID of the project.
- Environment
Id int - The ID of the Environment.
- Name string
Name of the Environment.
NOTE: One of either
environment_idornamemust be specified.
- Project
Id string - The ID of the project.
- Environment
Id int - The ID of the Environment.
- Name string
Name of the Environment.
NOTE: One of either
environment_idornamemust be specified.
- project
Id String - The ID of the project.
- environment
Id Integer - The ID of the Environment.
- name String
Name of the Environment.
NOTE: One of either
environment_idornamemust be specified.
- project
Id string - The ID of the project.
- environment
Id number - The ID of the Environment.
- name string
Name of the Environment.
NOTE: One of either
environment_idornamemust be specified.
- project_
id str - The ID of the project.
- environment_
id int - The ID of the Environment.
- name str
Name of the Environment.
NOTE: One of either
environment_idornamemust be specified.
- project
Id String - The ID of the project.
- environment
Id Number - The ID of the Environment.
- name String
Name of the Environment.
NOTE: One of either
environment_idornamemust be specified.
getEnvironment Result
The following output properties are available:
- Description string
- A description for the Environment.
- Id string
- The provider-assigned unique ID for this managed resource.
- Name string
- The name of the Environment.
- Project
Id string - Environment
Id int
- Description string
- A description for the Environment.
- Id string
- The provider-assigned unique ID for this managed resource.
- Name string
- The name of the Environment.
- Project
Id string - Environment
Id int
- description String
- A description for the Environment.
- id String
- The provider-assigned unique ID for this managed resource.
- name String
- The name of the Environment.
- project
Id String - environment
Id Integer
- description string
- A description for the Environment.
- id string
- The provider-assigned unique ID for this managed resource.
- name string
- The name of the Environment.
- project
Id string - environment
Id number
- description str
- A description for the Environment.
- id str
- The provider-assigned unique ID for this managed resource.
- name str
- The name of the Environment.
- project_
id str - environment_
id int
- description String
- A description for the Environment.
- id String
- The provider-assigned unique ID for this managed resource.
- name String
- The name of the Environment.
- project
Id String - environment
Id Number
Package Details
- Repository
- Azure DevOps pulumi/pulumi-azuredevops
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
azuredevopsTerraform Provider.
published on Monday, Mar 9, 2026 by Pulumi
