1. Registry
  2. Packages
  3. Cloudfoundry Provider
  4. API Docs
  5. getOrg
Viewing docs for cloudfoundry 1.19.0
published on Friday, Nov 13, 2026 by cloudfoundry
cloudfoundry
Viewing docs for cloudfoundry 1.19.0
published on Friday, Nov 13, 2026 by cloudfoundry

    Gets information on a Cloud Foundry organization.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as cloudfoundry from "@pulumi/cloudfoundry";
    
    const org = cloudfoundry.getOrg({
        name: "PerformanceTeamBLR",
    });
    export const id = org.then(org => org.id);
    export const labels = org.then(org => org.labels);
    
    import pulumi
    import pulumi_cloudfoundry as cloudfoundry
    
    org = cloudfoundry.get_org(name="PerformanceTeamBLR")
    pulumi.export("id", org.id)
    pulumi.export("labels", org.labels)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/cloudfoundry/cloudfoundry"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		org, err := cloudfoundry.LookupOrg(ctx, &cloudfoundry.LookupOrgArgs{
    			Name: "PerformanceTeamBLR",
    		}, nil)
    		if err != nil {
    			return err
    		}
    		ctx.Export("id", org.Id)
    		ctx.Export("labels", org.Labels)
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Cloudfoundry = Pulumi.Cloudfoundry;
    
    return await Deployment.RunAsync(() => 
    {
        var org = Cloudfoundry.GetOrg.Invoke(new()
        {
            Name = "PerformanceTeamBLR",
        });
    
        return new Dictionary<string, object?>
        {
            ["id"] = org.Apply(getOrgResult => getOrgResult.Id),
            ["labels"] = org.Apply(getOrgResult => getOrgResult.Labels),
        };
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.cloudfoundry.CloudfoundryFunctions;
    import com.pulumi.cloudfoundry.inputs.GetOrgArgs;
    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 org = CloudfoundryFunctions.getOrg(GetOrgArgs.builder()
                .name("PerformanceTeamBLR")
                .build());
    
            ctx.export("id", org.id());
            ctx.export("labels", org.labels());
        }
    }
    
    variables:
      org:
        fn::invoke:
          function: cloudfoundry:getOrg
          arguments:
            name: PerformanceTeamBLR
    outputs:
      id: ${org.id}
      labels: ${org.labels}
    
    Example coming soon!
    

    Using getOrg

    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 getOrg(args: GetOrgArgs, opts?: InvokeOptions): Promise<GetOrgResult>
    function getOrgOutput(args: GetOrgOutputArgs, opts?: InvokeOutputOptions): Output<GetOrgResult>
    def get_org(name: Optional[str] = None,
                opts: Optional[InvokeOptions] = None) -> GetOrgResult
    def get_org_output(name: pulumi.Input[Optional[str]] = None,
                opts: Optional[InvokeOutputOptions] = None) -> Output[GetOrgResult]
    func LookupOrg(ctx *Context, args *LookupOrgArgs, opts ...InvokeOption) (*LookupOrgResult, error)
    func LookupOrgOutput(ctx *Context, args *LookupOrgOutputArgs, opts ...InvokeOption) LookupOrgResultOutput

    > Note: This function is named LookupOrg in the Go SDK.

    public static class GetOrg 
    {
        public static Task<GetOrgResult> InvokeAsync(GetOrgArgs args, InvokeOptions? opts = null)
        public static Output<GetOrgResult> Invoke(GetOrgInvokeArgs args, InvokeOptions? opts = null)
        public static Output<GetOrgResult> Invoke(GetOrgInvokeArgs args, InvokeOutputOptions opts)
    }
    public static CompletableFuture<GetOrgResult> getOrg(GetOrgArgs args, InvokeOptions options)
    public static Output<GetOrgResult> getOrg(GetOrgArgs args, InvokeOptions options)
    public static Output<GetOrgResult> getOrg(GetOrgArgs args, InvokeOutputOptions options)
    
    fn::invoke:
      function: cloudfoundry:index/getOrg:getOrg
      arguments:
        # arguments dictionary
    data "cloudfoundry_get_org" "name" {
        # arguments
    }

    The following arguments are supported:

    Name string
    The name of the organization to look up
    Name string
    The name of the organization to look up
    name string
    The name of the organization to look up
    name String
    The name of the organization to look up
    name string
    The name of the organization to look up
    name str
    The name of the organization to look up
    name String
    The name of the organization to look up

    getOrg Result

    The following output properties are available:

    Annotations Dictionary<string, string>
    The annotations associated with Cloud Foundry resources.
    CreatedAt string
    The date and time when the resource was created in RFC3339 format.
    Id string
    The GUID of the object.
    Labels Dictionary<string, string>
    The labels associated with Cloud Foundry resources.
    Name string
    The name of the organization to look up
    Quota string
    The ID of quota to be applied to this Org. Default quota is assigned to the org by default.
    Suspended bool
    Whether an organization is suspended or not
    UpdatedAt string
    The date and time when the resource was updated in RFC3339 format.
    Annotations map[string]string
    The annotations associated with Cloud Foundry resources.
    CreatedAt string
    The date and time when the resource was created in RFC3339 format.
    Id string
    The GUID of the object.
    Labels map[string]string
    The labels associated with Cloud Foundry resources.
    Name string
    The name of the organization to look up
    Quota string
    The ID of quota to be applied to this Org. Default quota is assigned to the org by default.
    Suspended bool
    Whether an organization is suspended or not
    UpdatedAt string
    The date and time when the resource was updated in RFC3339 format.
    annotations map(string)
    The annotations associated with Cloud Foundry resources.
    created_at string
    The date and time when the resource was created in RFC3339 format.
    id string
    The GUID of the object.
    labels map(string)
    The labels associated with Cloud Foundry resources.
    name string
    The name of the organization to look up
    quota string
    The ID of quota to be applied to this Org. Default quota is assigned to the org by default.
    suspended bool
    Whether an organization is suspended or not
    updated_at string
    The date and time when the resource was updated in RFC3339 format.
    annotations Map<String,String>
    The annotations associated with Cloud Foundry resources.
    createdAt String
    The date and time when the resource was created in RFC3339 format.
    id String
    The GUID of the object.
    labels Map<String,String>
    The labels associated with Cloud Foundry resources.
    name String
    The name of the organization to look up
    quota String
    The ID of quota to be applied to this Org. Default quota is assigned to the org by default.
    suspended Boolean
    Whether an organization is suspended or not
    updatedAt String
    The date and time when the resource was updated in RFC3339 format.
    annotations {[key: string]: string}
    The annotations associated with Cloud Foundry resources.
    createdAt string
    The date and time when the resource was created in RFC3339 format.
    id string
    The GUID of the object.
    labels {[key: string]: string}
    The labels associated with Cloud Foundry resources.
    name string
    The name of the organization to look up
    quota string
    The ID of quota to be applied to this Org. Default quota is assigned to the org by default.
    suspended boolean
    Whether an organization is suspended or not
    updatedAt string
    The date and time when the resource was updated in RFC3339 format.
    annotations Mapping[str, str]
    The annotations associated with Cloud Foundry resources.
    created_at str
    The date and time when the resource was created in RFC3339 format.
    id str
    The GUID of the object.
    labels Mapping[str, str]
    The labels associated with Cloud Foundry resources.
    name str
    The name of the organization to look up
    quota str
    The ID of quota to be applied to this Org. Default quota is assigned to the org by default.
    suspended bool
    Whether an organization is suspended or not
    updated_at str
    The date and time when the resource was updated in RFC3339 format.
    annotations Map<String>
    The annotations associated with Cloud Foundry resources.
    createdAt String
    The date and time when the resource was created in RFC3339 format.
    id String
    The GUID of the object.
    labels Map<String>
    The labels associated with Cloud Foundry resources.
    name String
    The name of the organization to look up
    quota String
    The ID of quota to be applied to this Org. Default quota is assigned to the org by default.
    suspended Boolean
    Whether an organization is suspended or not
    updatedAt String
    The date and time when the resource was updated in RFC3339 format.

    Package Details

    Repository
    cloudfoundry cloudfoundry/terraform-provider-cloudfoundry
    License
    Notes
    This Pulumi package is based on the cloudfoundry Terraform Provider.
    cloudfoundry
    Viewing docs for cloudfoundry 1.19.0
    published on Friday, Nov 13, 2026 by cloudfoundry

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial