1. Registry
  2. Packages
  3. Snowflake Provider
  4. API Docs
  5. getReplicationGroups
Viewing docs for Snowflake v2.23.0
published on Friday, Nov 6, 2026 by Pulumi
snowflake logo
Viewing docs for Snowflake v2.23.0
published on Friday, Nov 6, 2026 by Pulumi

    Caution: Preview Feature This feature is considered a preview feature in the provider, regardless of the state of the resource in Snowflake. We do not guarantee its stability. It will be reworked and marked as a stable feature in future releases. Breaking changes are expected, even without bumping the major version. To use this feature, add the relevant feature name to previewFeaturesEnabled field in the provider configuration. Please always refer to the Getting Help section in our Github repo to best determine how to get help for your questions.

    Data source used to get details of replication groups. Filtering is aligned with the current possibilities for SHOW REPLICATION GROUPS query. The results of SHOW are encapsulated in one output collection replicationGroups.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as snowflake from "@pulumi/snowflake";
    
    // Simple usage
    const simple = snowflake.getReplicationGroups({});
    export const simpleOutput = simple.then(simple => simple.replicationGroups);
    // Filtering (in_account)
    const inAccount = snowflake.getReplicationGroups({
        inAccount: "\"<organization_name>\".\"<account_name>\"",
    });
    export const inAccountOutput = inAccount.then(inAccount => inAccount.replicationGroups);
    
    import pulumi
    import pulumi_snowflake as snowflake
    
    # Simple usage
    simple = snowflake.get_replication_groups()
    pulumi.export("simpleOutput", simple.replication_groups)
    # Filtering (in_account)
    in_account = snowflake.get_replication_groups(in_account="\"<organization_name>\".\"<account_name>\"")
    pulumi.export("inAccountOutput", in_account.replication_groups)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-snowflake/sdk/v2/go/snowflake"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		// Simple usage
    		simple, err := snowflake.GetReplicationGroups(ctx, &snowflake.GetReplicationGroupsArgs{}, nil)
    		if err != nil {
    			return err
    		}
    		ctx.Export("simpleOutput", simple.ReplicationGroups)
    		// Filtering (in_account)
    		inAccount, err := snowflake.GetReplicationGroups(ctx, &snowflake.GetReplicationGroupsArgs{
    			InAccount: pulumi.StringRef("\"<organization_name>\".\"<account_name>\""),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		ctx.Export("inAccountOutput", inAccount.ReplicationGroups)
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Snowflake = Pulumi.Snowflake;
    
    return await Deployment.RunAsync(() => 
    {
        // Simple usage
        var simple = Snowflake.GetReplicationGroups.Invoke();
    
        // Filtering (in_account)
        var inAccount = Snowflake.GetReplicationGroups.Invoke(new()
        {
            InAccount = "\"<organization_name>\".\"<account_name>\"",
        });
    
        return new Dictionary<string, object?>
        {
            ["simpleOutput"] = simple.Apply(getReplicationGroupsResult => getReplicationGroupsResult.ReplicationGroups),
            ["inAccountOutput"] = inAccount.Apply(getReplicationGroupsResult => getReplicationGroupsResult.ReplicationGroups),
        };
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.snowflake.SnowflakeFunctions;
    import com.pulumi.snowflake.inputs.GetReplicationGroupsArgs;
    import java.util.ArrayList;
    import java.util.Arrays;
    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) {
            // Simple usage
            final var simple = SnowflakeFunctions.getReplicationGroups(GetReplicationGroupsArgs.builder()
                .build());
    
            ctx.export("simpleOutput", simple.replicationGroups());
            // Filtering (in_account)
            final var inAccount = SnowflakeFunctions.getReplicationGroups(GetReplicationGroupsArgs.builder()
                .inAccount("\"<organization_name>\".\"<account_name>\"")
                .build());
    
            ctx.export("inAccountOutput", inAccount.replicationGroups());
        }
    }
    
    variables:
      # Simple usage
      simple:
        fn::invoke:
          function: snowflake:getReplicationGroups
          arguments: {}
      # Filtering (in_account)
      inAccount:
        fn::invoke:
          function: snowflake:getReplicationGroups
          arguments:
            inAccount: '"<organization_name>"."<account_name>"'
    outputs:
      simpleOutput: ${simple.replicationGroups}
      inAccountOutput: ${inAccount.replicationGroups}
    
    terraform {
      required_providers {
        snowflake = {
          source = "pulumi/snowflake"
        }
      }
    }
    
    data "snowflake_replication_groups" "simple" {
    }
    data "snowflake_replication_groups" "inAccount" {
      in_account = "\"<organization_name>\".\"<account_name>\""
    }
    
    # Simple usage
    output "simpleOutput" {
      value = data.snowflake_replication_groups.simple.replication_groups
    }
    # Filtering (in_account)
    output "inAccountOutput" {
      value = data.snowflake_replication_groups.inAccount.replication_groups
    }
    

    Note If a field has a default value, it is shown next to the type in the schema.

    Using getReplicationGroups

    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 getReplicationGroups(args: GetReplicationGroupsArgs, opts?: InvokeOptions): Promise<GetReplicationGroupsResult>
    function getReplicationGroupsOutput(args: GetReplicationGroupsOutputArgs, opts?: InvokeOutputOptions): Output<GetReplicationGroupsResult>
    def get_replication_groups(in_account: Optional[str] = None,
                               opts: Optional[InvokeOptions] = None) -> GetReplicationGroupsResult
    def get_replication_groups_output(in_account: pulumi.Input[Optional[str]] = None,
                               opts: Optional[InvokeOutputOptions] = None) -> Output[GetReplicationGroupsResult]
    func GetReplicationGroups(ctx *Context, args *GetReplicationGroupsArgs, opts ...InvokeOption) (*GetReplicationGroupsResult, error)
    func GetReplicationGroupsOutput(ctx *Context, args *GetReplicationGroupsOutputArgs, opts ...InvokeOption) GetReplicationGroupsResultOutput

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

    public static class GetReplicationGroups 
    {
        public static Task<GetReplicationGroupsResult> InvokeAsync(GetReplicationGroupsArgs args, InvokeOptions? opts = null)
        public static Output<GetReplicationGroupsResult> Invoke(GetReplicationGroupsInvokeArgs args, InvokeOptions? opts = null)
        public static Output<GetReplicationGroupsResult> Invoke(GetReplicationGroupsInvokeArgs args, InvokeOutputOptions opts)
    }
    public static CompletableFuture<GetReplicationGroupsResult> getReplicationGroups(GetReplicationGroupsArgs args, InvokeOptions options)
    public static Output<GetReplicationGroupsResult> getReplicationGroups(GetReplicationGroupsArgs args, InvokeOptions options)
    public static Output<GetReplicationGroupsResult> getReplicationGroups(GetReplicationGroupsArgs args, InvokeOutputOptions options)
    
    fn::invoke:
      function: snowflake:index/getReplicationGroups:getReplicationGroups
      arguments:
        # arguments dictionary
    data "snowflake_get_replication_groups" "name" {
        # arguments
    }

    The following arguments are supported:

    InAccount string
    Limits results to replication groups in this account, as organization and account name. Matches SHOW REPLICATION GROUPS IN ACCOUNT.
    InAccount string
    Limits results to replication groups in this account, as organization and account name. Matches SHOW REPLICATION GROUPS IN ACCOUNT.
    in_account string
    Limits results to replication groups in this account, as organization and account name. Matches SHOW REPLICATION GROUPS IN ACCOUNT.
    inAccount String
    Limits results to replication groups in this account, as organization and account name. Matches SHOW REPLICATION GROUPS IN ACCOUNT.
    inAccount string
    Limits results to replication groups in this account, as organization and account name. Matches SHOW REPLICATION GROUPS IN ACCOUNT.
    in_account str
    Limits results to replication groups in this account, as organization and account name. Matches SHOW REPLICATION GROUPS IN ACCOUNT.
    inAccount String
    Limits results to replication groups in this account, as organization and account name. Matches SHOW REPLICATION GROUPS IN ACCOUNT.

    getReplicationGroups Result

    The following output properties are available:

    Id string
    The provider-assigned unique ID for this managed resource.
    ReplicationGroups List<GetReplicationGroupsReplicationGroup>
    Holds the output of SHOW REPLICATION GROUPS.
    InAccount string
    Limits results to replication groups in this account, as organization and account name. Matches SHOW REPLICATION GROUPS IN ACCOUNT.
    Id string
    The provider-assigned unique ID for this managed resource.
    ReplicationGroups []GetReplicationGroupsReplicationGroup
    Holds the output of SHOW REPLICATION GROUPS.
    InAccount string
    Limits results to replication groups in this account, as organization and account name. Matches SHOW REPLICATION GROUPS IN ACCOUNT.
    id string
    The provider-assigned unique ID for this managed resource.
    replication_groups list(object)
    Holds the output of SHOW REPLICATION GROUPS.
    in_account string
    Limits results to replication groups in this account, as organization and account name. Matches SHOW REPLICATION GROUPS IN ACCOUNT.
    id String
    The provider-assigned unique ID for this managed resource.
    replicationGroups List<GetReplicationGroupsReplicationGroup>
    Holds the output of SHOW REPLICATION GROUPS.
    inAccount String
    Limits results to replication groups in this account, as organization and account name. Matches SHOW REPLICATION GROUPS IN ACCOUNT.
    id string
    The provider-assigned unique ID for this managed resource.
    replicationGroups GetReplicationGroupsReplicationGroup[]
    Holds the output of SHOW REPLICATION GROUPS.
    inAccount string
    Limits results to replication groups in this account, as organization and account name. Matches SHOW REPLICATION GROUPS IN ACCOUNT.
    id str
    The provider-assigned unique ID for this managed resource.
    replication_groups Sequence[GetReplicationGroupsReplicationGroup]
    Holds the output of SHOW REPLICATION GROUPS.
    in_account str
    Limits results to replication groups in this account, as organization and account name. Matches SHOW REPLICATION GROUPS IN ACCOUNT.
    id String
    The provider-assigned unique ID for this managed resource.
    replicationGroups List<Property Map>
    Holds the output of SHOW REPLICATION GROUPS.
    inAccount String
    Limits results to replication groups in this account, as organization and account name. Matches SHOW REPLICATION GROUPS IN ACCOUNT.

    Supporting Types

    GetReplicationGroupsReplicationGroup

    ShowOutputs List<GetReplicationGroupsReplicationGroupShowOutput>
    Holds the output of SHOW REPLICATION GROUPS.
    ShowOutputs []GetReplicationGroupsReplicationGroupShowOutput
    Holds the output of SHOW REPLICATION GROUPS.
    show_outputs list(object)
    Holds the output of SHOW REPLICATION GROUPS.
    showOutputs List<GetReplicationGroupsReplicationGroupShowOutput>
    Holds the output of SHOW REPLICATION GROUPS.
    showOutputs GetReplicationGroupsReplicationGroupShowOutput[]
    Holds the output of SHOW REPLICATION GROUPS.
    showOutputs List<Property Map>
    Holds the output of SHOW REPLICATION GROUPS.

    GetReplicationGroupsReplicationGroupShowOutput

    Package Details

    Repository
    Snowflake pulumi/pulumi-snowflake
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the snowflake Terraform Provider.
    snowflake logo
    Viewing docs for Snowflake v2.23.0
    published on Friday, Nov 6, 2026 by Pulumi

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial