Harness v0.7.0 published on Friday, Mar 28, 2025 by Pulumi
harness.platform.getVariables
Explore with Pulumi AI
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as harness from "@pulumi/harness";
const example = harness.platform.getVariables({
    identifier: "identifier",
    orgId: "org_id",
    projectId: "project_id",
});
import pulumi
import pulumi_harness as harness
example = harness.platform.get_variables(identifier="identifier",
    org_id="org_id",
    project_id="project_id")
package main
import (
	"github.com/pulumi/pulumi-harness/sdk/go/harness/platform"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := platform.LookupVariables(ctx, &platform.LookupVariablesArgs{
			Identifier: "identifier",
			OrgId:      pulumi.StringRef("org_id"),
			ProjectId:  pulumi.StringRef("project_id"),
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Harness = Pulumi.Harness;
return await Deployment.RunAsync(() => 
{
    var example = Harness.Platform.GetVariables.Invoke(new()
    {
        Identifier = "identifier",
        OrgId = "org_id",
        ProjectId = "project_id",
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.harness.platform.PlatformFunctions;
import com.pulumi.harness.platform.inputs.GetVariablesArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }
    public static void stack(Context ctx) {
        final var example = PlatformFunctions.getVariables(GetVariablesArgs.builder()
            .identifier("identifier")
            .orgId("org_id")
            .projectId("project_id")
            .build());
    }
}
variables:
  example:
    fn::invoke:
      function: harness:platform:getVariables
      arguments:
        identifier: identifier
        orgId: org_id
        projectId: project_id
Using getVariables
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 getVariables(args: GetVariablesArgs, opts?: InvokeOptions): Promise<GetVariablesResult>
function getVariablesOutput(args: GetVariablesOutputArgs, opts?: InvokeOptions): Output<GetVariablesResult>def get_variables(identifier: Optional[str] = None,
                  org_id: Optional[str] = None,
                  project_id: Optional[str] = None,
                  opts: Optional[InvokeOptions] = None) -> GetVariablesResult
def get_variables_output(identifier: Optional[pulumi.Input[str]] = None,
                  org_id: Optional[pulumi.Input[str]] = None,
                  project_id: Optional[pulumi.Input[str]] = None,
                  opts: Optional[InvokeOptions] = None) -> Output[GetVariablesResult]func LookupVariables(ctx *Context, args *LookupVariablesArgs, opts ...InvokeOption) (*LookupVariablesResult, error)
func LookupVariablesOutput(ctx *Context, args *LookupVariablesOutputArgs, opts ...InvokeOption) LookupVariablesResultOutput> Note: This function is named LookupVariables in the Go SDK.
public static class GetVariables 
{
    public static Task<GetVariablesResult> InvokeAsync(GetVariablesArgs args, InvokeOptions? opts = null)
    public static Output<GetVariablesResult> Invoke(GetVariablesInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetVariablesResult> getVariables(GetVariablesArgs args, InvokeOptions options)
public static Output<GetVariablesResult> getVariables(GetVariablesArgs args, InvokeOptions options)
fn::invoke:
  function: harness:platform/getVariables:getVariables
  arguments:
    # arguments dictionaryThe following arguments are supported:
- Identifier string
 - Unique identifier of the resource
 - Org
Id string - Organization Identifier for the Entity
 - Project
Id string - Project Identifier for the Entity
 
- Identifier string
 - Unique identifier of the resource
 - Org
Id string - Organization Identifier for the Entity
 - Project
Id string - Project Identifier for the Entity
 
- identifier String
 - Unique identifier of the resource
 - org
Id String - Organization Identifier for the Entity
 - project
Id String - Project Identifier for the Entity
 
- identifier string
 - Unique identifier of the resource
 - org
Id string - Organization Identifier for the Entity
 - project
Id string - Project Identifier for the Entity
 
- identifier str
 - Unique identifier of the resource
 - org_
id str - Organization Identifier for the Entity
 - project_
id str - Project Identifier for the Entity
 
- identifier String
 - Unique identifier of the resource
 - org
Id String - Organization Identifier for the Entity
 - project
Id String - Project Identifier for the Entity
 
getVariables Result
The following output properties are available:
- Description string
 - Description of the entity
 - Id string
 - The provider-assigned unique ID for this managed resource.
 - Identifier string
 - Unique identifier of the resource
 - Name string
 - Name of the Variable
 - Specs
List<Get
Variables Spec>  - List of Spce Fields.
 - Type string
 - Type of Variable
 - Org
Id string - Organization Identifier for the Entity
 - Project
Id string - Project Identifier for the Entity
 
- Description string
 - Description of the entity
 - Id string
 - The provider-assigned unique ID for this managed resource.
 - Identifier string
 - Unique identifier of the resource
 - Name string
 - Name of the Variable
 - Specs
[]Get
Variables Spec  - List of Spce Fields.
 - Type string
 - Type of Variable
 - Org
Id string - Organization Identifier for the Entity
 - Project
Id string - Project Identifier for the Entity
 
- description String
 - Description of the entity
 - id String
 - The provider-assigned unique ID for this managed resource.
 - identifier String
 - Unique identifier of the resource
 - name String
 - Name of the Variable
 - specs
List<Get
Variables Spec>  - List of Spce Fields.
 - type String
 - Type of Variable
 - org
Id String - Organization Identifier for the Entity
 - project
Id String - Project Identifier for the Entity
 
- description string
 - Description of the entity
 - id string
 - The provider-assigned unique ID for this managed resource.
 - identifier string
 - Unique identifier of the resource
 - name string
 - Name of the Variable
 - specs
Get
Variables Spec[]  - List of Spce Fields.
 - type string
 - Type of Variable
 - org
Id string - Organization Identifier for the Entity
 - project
Id string - Project Identifier for the Entity
 
- description str
 - Description of the entity
 - id str
 - The provider-assigned unique ID for this managed resource.
 - identifier str
 - Unique identifier of the resource
 - name str
 - Name of the Variable
 - specs
Sequence[Get
Variables Spec]  - List of Spce Fields.
 - type str
 - Type of Variable
 - org_
id str - Organization Identifier for the Entity
 - project_
id str - Project Identifier for the Entity
 
- description String
 - Description of the entity
 - id String
 - The provider-assigned unique ID for this managed resource.
 - identifier String
 - Unique identifier of the resource
 - name String
 - Name of the Variable
 - specs List<Property Map>
 - List of Spce Fields.
 - type String
 - Type of Variable
 - org
Id String - Organization Identifier for the Entity
 - project
Id String - Project Identifier for the Entity
 
Supporting Types
GetVariablesSpec  
- Fixed
Value string - FixedValue of the variable
 - Value
Type string - Type of Value of the Variable. For now only FIXED is supported
 
- Fixed
Value string - FixedValue of the variable
 - Value
Type string - Type of Value of the Variable. For now only FIXED is supported
 
- fixed
Value String - FixedValue of the variable
 - value
Type String - Type of Value of the Variable. For now only FIXED is supported
 
- fixed
Value string - FixedValue of the variable
 - value
Type string - Type of Value of the Variable. For now only FIXED is supported
 
- fixed_
value str - FixedValue of the variable
 - value_
type str - Type of Value of the Variable. For now only FIXED is supported
 
- fixed
Value String - FixedValue of the variable
 - value
Type String - Type of Value of the Variable. For now only FIXED is supported
 
Package Details
- Repository
 - harness pulumi/pulumi-harness
 - License
 - Apache-2.0
 - Notes
 - This Pulumi package is based on the 
harnessTerraform Provider.