Alibaba Cloud v3.75.0 published on Friday, Mar 7, 2025 by Pulumi
alicloud.oos.getApplications
Explore with Pulumi AI
This data source provides the Oos Applications of the current Alibaba Cloud user.
NOTE: Available in v1.145.0+.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const ids = alicloud.oos.getApplications({});
export const oosApplicationId1 = ids.then(ids => ids.applications?.[0]?.id);
const nameRegex = alicloud.oos.getApplications({
    nameRegex: "^my-Application",
});
export const oosApplicationId2 = nameRegex.then(nameRegex => nameRegex.applications?.[0]?.id);
import pulumi
import pulumi_alicloud as alicloud
ids = alicloud.oos.get_applications()
pulumi.export("oosApplicationId1", ids.applications[0].id)
name_regex = alicloud.oos.get_applications(name_regex="^my-Application")
pulumi.export("oosApplicationId2", name_regex.applications[0].id)
package main
import (
	"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/oos"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		ids, err := oos.GetApplications(ctx, &oos.GetApplicationsArgs{}, nil)
		if err != nil {
			return err
		}
		ctx.Export("oosApplicationId1", ids.Applications[0].Id)
		nameRegex, err := oos.GetApplications(ctx, &oos.GetApplicationsArgs{
			NameRegex: pulumi.StringRef("^my-Application"),
		}, nil)
		if err != nil {
			return err
		}
		ctx.Export("oosApplicationId2", nameRegex.Applications[0].Id)
		return nil
	})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() => 
{
    var ids = AliCloud.Oos.GetApplications.Invoke();
    var nameRegex = AliCloud.Oos.GetApplications.Invoke(new()
    {
        NameRegex = "^my-Application",
    });
    return new Dictionary<string, object?>
    {
        ["oosApplicationId1"] = ids.Apply(getApplicationsResult => getApplicationsResult.Applications[0]?.Id),
        ["oosApplicationId2"] = nameRegex.Apply(getApplicationsResult => getApplicationsResult.Applications[0]?.Id),
    };
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.oos.OosFunctions;
import com.pulumi.alicloud.oos.inputs.GetApplicationsArgs;
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 ids = OosFunctions.getApplications();
        ctx.export("oosApplicationId1", ids.applyValue(getApplicationsResult -> getApplicationsResult.applications()[0].id()));
        final var nameRegex = OosFunctions.getApplications(GetApplicationsArgs.builder()
            .nameRegex("^my-Application")
            .build());
        ctx.export("oosApplicationId2", nameRegex.applyValue(getApplicationsResult -> getApplicationsResult.applications()[0].id()));
    }
}
variables:
  ids:
    fn::invoke:
      function: alicloud:oos:getApplications
      arguments: {}
  nameRegex:
    fn::invoke:
      function: alicloud:oos:getApplications
      arguments:
        nameRegex: ^my-Application
outputs:
  oosApplicationId1: ${ids.applications[0].id}
  oosApplicationId2: ${nameRegex.applications[0].id}
Using getApplications
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 getApplications(args: GetApplicationsArgs, opts?: InvokeOptions): Promise<GetApplicationsResult>
function getApplicationsOutput(args: GetApplicationsOutputArgs, opts?: InvokeOptions): Output<GetApplicationsResult>def get_applications(ids: Optional[Sequence[str]] = None,
                     name_regex: Optional[str] = None,
                     output_file: Optional[str] = None,
                     tags: Optional[Mapping[str, str]] = None,
                     opts: Optional[InvokeOptions] = None) -> GetApplicationsResult
def get_applications_output(ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
                     name_regex: Optional[pulumi.Input[str]] = None,
                     output_file: Optional[pulumi.Input[str]] = None,
                     tags: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
                     opts: Optional[InvokeOptions] = None) -> Output[GetApplicationsResult]func GetApplications(ctx *Context, args *GetApplicationsArgs, opts ...InvokeOption) (*GetApplicationsResult, error)
func GetApplicationsOutput(ctx *Context, args *GetApplicationsOutputArgs, opts ...InvokeOption) GetApplicationsResultOutput> Note: This function is named GetApplications in the Go SDK.
public static class GetApplications 
{
    public static Task<GetApplicationsResult> InvokeAsync(GetApplicationsArgs args, InvokeOptions? opts = null)
    public static Output<GetApplicationsResult> Invoke(GetApplicationsInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetApplicationsResult> getApplications(GetApplicationsArgs args, InvokeOptions options)
public static Output<GetApplicationsResult> getApplications(GetApplicationsArgs args, InvokeOptions options)
fn::invoke:
  function: alicloud:oos/getApplications:getApplications
  arguments:
    # arguments dictionaryThe following arguments are supported:
- Ids List<string>
- A list of Application IDs. Its element value is same as Application Name.
- NameRegex string
- A regex string to filter results by Application name.
- OutputFile string
- File name where to save data source results (after running pulumi preview).
- Dictionary<string, string>
- A mapping of tags to assign to the resource.
- Ids []string
- A list of Application IDs. Its element value is same as Application Name.
- NameRegex string
- A regex string to filter results by Application name.
- OutputFile string
- File name where to save data source results (after running pulumi preview).
- map[string]string
- A mapping of tags to assign to the resource.
- ids List<String>
- A list of Application IDs. Its element value is same as Application Name.
- nameRegex String
- A regex string to filter results by Application name.
- outputFile String
- File name where to save data source results (after running pulumi preview).
- Map<String,String>
- A mapping of tags to assign to the resource.
- ids string[]
- A list of Application IDs. Its element value is same as Application Name.
- nameRegex string
- A regex string to filter results by Application name.
- outputFile string
- File name where to save data source results (after running pulumi preview).
- {[key: string]: string}
- A mapping of tags to assign to the resource.
- ids Sequence[str]
- A list of Application IDs. Its element value is same as Application Name.
- name_regex str
- A regex string to filter results by Application name.
- output_file str
- File name where to save data source results (after running pulumi preview).
- Mapping[str, str]
- A mapping of tags to assign to the resource.
- ids List<String>
- A list of Application IDs. Its element value is same as Application Name.
- nameRegex String
- A regex string to filter results by Application name.
- outputFile String
- File name where to save data source results (after running pulumi preview).
- Map<String>
- A mapping of tags to assign to the resource.
getApplications Result
The following output properties are available:
- Applications
List<Pulumi.Ali Cloud. Oos. Outputs. Get Applications Application> 
- Id string
- The provider-assigned unique ID for this managed resource.
- Ids List<string>
- Names List<string>
- NameRegex string
- OutputFile string
- Dictionary<string, string>
- Applications
[]GetApplications Application 
- Id string
- The provider-assigned unique ID for this managed resource.
- Ids []string
- Names []string
- NameRegex string
- OutputFile string
- map[string]string
- applications
List<GetApplications Application> 
- id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- names List<String>
- nameRegex String
- outputFile String
- Map<String,String>
- applications
GetApplications Application[] 
- id string
- The provider-assigned unique ID for this managed resource.
- ids string[]
- names string[]
- nameRegex string
- outputFile string
- {[key: string]: string}
- applications
Sequence[GetApplications Application] 
- id str
- The provider-assigned unique ID for this managed resource.
- ids Sequence[str]
- names Sequence[str]
- name_regex str
- output_file str
- Mapping[str, str]
- applications List<Property Map>
- id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- names List<String>
- nameRegex String
- outputFile String
- Map<String>
Supporting Types
GetApplicationsApplication  
- ApplicationName string
- The name of the application.
- CreateTime string
- The Created time of the application.
- Description string
- Application group description information.
- Id string
- The ID of the Application. The value is formate as <application_name>.
- ResourceGroup stringId 
- The ID of the resource group.
- Dictionary<string, string>
- The tag of the resource.
- UpdateTime string
- The Updated time of the application.
- ApplicationName string
- The name of the application.
- CreateTime string
- The Created time of the application.
- Description string
- Application group description information.
- Id string
- The ID of the Application. The value is formate as <application_name>.
- ResourceGroup stringId 
- The ID of the resource group.
- map[string]string
- The tag of the resource.
- UpdateTime string
- The Updated time of the application.
- applicationName String
- The name of the application.
- createTime String
- The Created time of the application.
- description String
- Application group description information.
- id String
- The ID of the Application. The value is formate as <application_name>.
- resourceGroup StringId 
- The ID of the resource group.
- Map<String,String>
- The tag of the resource.
- updateTime String
- The Updated time of the application.
- applicationName string
- The name of the application.
- createTime string
- The Created time of the application.
- description string
- Application group description information.
- id string
- The ID of the Application. The value is formate as <application_name>.
- resourceGroup stringId 
- The ID of the resource group.
- {[key: string]: string}
- The tag of the resource.
- updateTime string
- The Updated time of the application.
- application_name str
- The name of the application.
- create_time str
- The Created time of the application.
- description str
- Application group description information.
- id str
- The ID of the Application. The value is formate as <application_name>.
- resource_group_ strid 
- The ID of the resource group.
- Mapping[str, str]
- The tag of the resource.
- update_time str
- The Updated time of the application.
- applicationName String
- The name of the application.
- createTime String
- The Created time of the application.
- description String
- Application group description information.
- id String
- The ID of the Application. The value is formate as <application_name>.
- resourceGroup StringId 
- The ID of the resource group.
- Map<String>
- The tag of the resource.
- updateTime String
- The Updated time of the application.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the alicloudTerraform Provider.