Alibaba Cloud v3.88.1 published on Saturday, Nov 8, 2025 by Pulumi
Alibaba Cloud v3.88.1 published on Saturday, Nov 8, 2025 by Pulumi
This data source provides the Log Stores of the current Alibaba Cloud user.
NOTE: Available in v1.126.0+.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const example = alicloud.log.getStores({
project: "the_project_name",
ids: ["the_store_name"],
});
export const firstLogStoreId = example.then(example => example.stores?.[0]?.id);
import pulumi
import pulumi_alicloud as alicloud
example = alicloud.log.get_stores(project="the_project_name",
ids=["the_store_name"])
pulumi.export("firstLogStoreId", example.stores[0].id)
package main
import (
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/log"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
example, err := log.GetStores(ctx, &log.GetStoresArgs{
Project: "the_project_name",
Ids: []string{
"the_store_name",
},
}, nil)
if err != nil {
return err
}
ctx.Export("firstLogStoreId", example.Stores[0].Id)
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var example = AliCloud.Log.GetStores.Invoke(new()
{
Project = "the_project_name",
Ids = new[]
{
"the_store_name",
},
});
return new Dictionary<string, object?>
{
["firstLogStoreId"] = example.Apply(getStoresResult => getStoresResult.Stores[0]?.Id),
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.log.LogFunctions;
import com.pulumi.alicloud.log.inputs.GetStoresArgs;
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 = LogFunctions.getStores(GetStoresArgs.builder()
.project("the_project_name")
.ids("the_store_name")
.build());
ctx.export("firstLogStoreId", example.stores()[0].id());
}
}
variables:
example:
fn::invoke:
function: alicloud:log:getStores
arguments:
project: the_project_name
ids:
- the_store_name
outputs:
firstLogStoreId: ${example.stores[0].id}
Using getStores
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 getStores(args: GetStoresArgs, opts?: InvokeOptions): Promise<GetStoresResult>
function getStoresOutput(args: GetStoresOutputArgs, opts?: InvokeOptions): Output<GetStoresResult>def get_stores(ids: Optional[Sequence[str]] = None,
name_regex: Optional[str] = None,
output_file: Optional[str] = None,
project: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetStoresResult
def get_stores_output(ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
name_regex: Optional[pulumi.Input[str]] = None,
output_file: Optional[pulumi.Input[str]] = None,
project: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetStoresResult]func GetStores(ctx *Context, args *GetStoresArgs, opts ...InvokeOption) (*GetStoresResult, error)
func GetStoresOutput(ctx *Context, args *GetStoresOutputArgs, opts ...InvokeOption) GetStoresResultOutput> Note: This function is named GetStores in the Go SDK.
public static class GetStores
{
public static Task<GetStoresResult> InvokeAsync(GetStoresArgs args, InvokeOptions? opts = null)
public static Output<GetStoresResult> Invoke(GetStoresInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetStoresResult> getStores(GetStoresArgs args, InvokeOptions options)
public static Output<GetStoresResult> getStores(GetStoresArgs args, InvokeOptions options)
fn::invoke:
function: alicloud:log/getStores:getStores
arguments:
# arguments dictionaryThe following arguments are supported:
- Project string
- Ids List<string>
- A list of store IDs.
- Name
Regex string - A regex string to filter results by store name.
- Output
File string - File name where to save data source results (after running
pulumi preview).
- Project string
- Ids []string
- A list of store IDs.
- Name
Regex string - A regex string to filter results by store name.
- Output
File string - File name where to save data source results (after running
pulumi preview).
- project String
- ids List<String>
- A list of store IDs.
- name
Regex String - A regex string to filter results by store name.
- output
File String - File name where to save data source results (after running
pulumi preview).
- project string
- ids string[]
- A list of store IDs.
- name
Regex string - A regex string to filter results by store name.
- output
File string - File name where to save data source results (after running
pulumi preview).
- project str
- ids Sequence[str]
- A list of store IDs.
- name_
regex str - A regex string to filter results by store name.
- output_
file str - File name where to save data source results (after running
pulumi preview).
- project String
- ids List<String>
- A list of store IDs.
- name
Regex String - A regex string to filter results by store name.
- output
File String - File name where to save data source results (after running
pulumi preview).
getStores Result
The following output properties are available:
- Id string
- The provider-assigned unique ID for this managed resource.
- Ids List<string>
- Names List<string>
- Project string
- Stores
List<Pulumi.
Ali Cloud. Log. Outputs. Get Stores Store> - Name
Regex string - Output
File string
- Id string
- The provider-assigned unique ID for this managed resource.
- Ids []string
- Names []string
- Project string
- Stores
[]Get
Stores Store - Name
Regex string - Output
File string
- id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- names List<String>
- project String
- stores
List<Get
Stores Store> - name
Regex String - output
File String
- id string
- The provider-assigned unique ID for this managed resource.
- ids string[]
- names string[]
- project string
- stores
Get
Stores Store[] - name
Regex string - output
File string
- id str
- The provider-assigned unique ID for this managed resource.
- ids Sequence[str]
- names Sequence[str]
- project str
- stores
Sequence[Get
Stores Store] - name_
regex str - output_
file str
- id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- names List<String>
- project String
- stores List<Property Map>
- name
Regex String - output
File String
Supporting Types
GetStoresStore
- id str
- The ID of the store.
- store_
name str - The name of the store.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
alicloudTerraform Provider.
Alibaba Cloud v3.88.1 published on Saturday, Nov 8, 2025 by Pulumi
