1. Packages
  2. Ibm Provider
  3. API Docs
  4. getIsVpnGatewayAdvertisedCidrs
ibm 1.86.0 published on Wednesday, Dec 3, 2025 by ibm-cloud
ibm logo
ibm 1.86.0 published on Wednesday, Dec 3, 2025 by ibm-cloud

    Provides a read-only data source to retrieve information about VPNGatewayAdvertisedCIDRs. You can then reference the fields of the data source in other resources within the same configuration by using interpolation syntax.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as ibm from "@pulumi/ibm";
    
    const example = ibm.getIsVpnGatewayAdvertisedCidrs({
        vpnGateway: exampleIbmIsVpnGateway.id,
    });
    const example_2 = ibm.getIsVpnGatewayAdvertisedCidrs({
        vpnGatewayName: exampleIbmIsVpnGateway.name,
    });
    
    import pulumi
    import pulumi_ibm as ibm
    
    example = ibm.get_is_vpn_gateway_advertised_cidrs(vpn_gateway=example_ibm_is_vpn_gateway["id"])
    example_2 = ibm.get_is_vpn_gateway_advertised_cidrs(vpn_gateway_name=example_ibm_is_vpn_gateway["name"])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/ibm/ibm"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := ibm.GetIsVpnGatewayAdvertisedCidrs(ctx, &ibm.GetIsVpnGatewayAdvertisedCidrsArgs{
    			VpnGateway: pulumi.StringRef(exampleIbmIsVpnGateway.Id),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		_, err = ibm.GetIsVpnGatewayAdvertisedCidrs(ctx, &ibm.GetIsVpnGatewayAdvertisedCidrsArgs{
    			VpnGatewayName: pulumi.StringRef(exampleIbmIsVpnGateway.Name),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ibm = Pulumi.Ibm;
    
    return await Deployment.RunAsync(() => 
    {
        var example = Ibm.GetIsVpnGatewayAdvertisedCidrs.Invoke(new()
        {
            VpnGateway = exampleIbmIsVpnGateway.Id,
        });
    
        var example_2 = Ibm.GetIsVpnGatewayAdvertisedCidrs.Invoke(new()
        {
            VpnGatewayName = exampleIbmIsVpnGateway.Name,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ibm.IbmFunctions;
    import com.pulumi.ibm.inputs.GetIsVpnGatewayAdvertisedCidrsArgs;
    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 = IbmFunctions.getIsVpnGatewayAdvertisedCidrs(GetIsVpnGatewayAdvertisedCidrsArgs.builder()
                .vpnGateway(exampleIbmIsVpnGateway.id())
                .build());
    
            final var example-2 = IbmFunctions.getIsVpnGatewayAdvertisedCidrs(GetIsVpnGatewayAdvertisedCidrsArgs.builder()
                .vpnGatewayName(exampleIbmIsVpnGateway.name())
                .build());
    
        }
    }
    
    variables:
      example:
        fn::invoke:
          function: ibm:getIsVpnGatewayAdvertisedCidrs
          arguments:
            vpnGateway: ${exampleIbmIsVpnGateway.id}
      example-2:
        fn::invoke:
          function: ibm:getIsVpnGatewayAdvertisedCidrs
          arguments:
            vpnGatewayName: ${exampleIbmIsVpnGateway.name}
    

    Using getIsVpnGatewayAdvertisedCidrs

    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 getIsVpnGatewayAdvertisedCidrs(args: GetIsVpnGatewayAdvertisedCidrsArgs, opts?: InvokeOptions): Promise<GetIsVpnGatewayAdvertisedCidrsResult>
    function getIsVpnGatewayAdvertisedCidrsOutput(args: GetIsVpnGatewayAdvertisedCidrsOutputArgs, opts?: InvokeOptions): Output<GetIsVpnGatewayAdvertisedCidrsResult>
    def get_is_vpn_gateway_advertised_cidrs(id: Optional[str] = None,
                                            vpn_gateway: Optional[str] = None,
                                            vpn_gateway_name: Optional[str] = None,
                                            opts: Optional[InvokeOptions] = None) -> GetIsVpnGatewayAdvertisedCidrsResult
    def get_is_vpn_gateway_advertised_cidrs_output(id: Optional[pulumi.Input[str]] = None,
                                            vpn_gateway: Optional[pulumi.Input[str]] = None,
                                            vpn_gateway_name: Optional[pulumi.Input[str]] = None,
                                            opts: Optional[InvokeOptions] = None) -> Output[GetIsVpnGatewayAdvertisedCidrsResult]
    func GetIsVpnGatewayAdvertisedCidrs(ctx *Context, args *GetIsVpnGatewayAdvertisedCidrsArgs, opts ...InvokeOption) (*GetIsVpnGatewayAdvertisedCidrsResult, error)
    func GetIsVpnGatewayAdvertisedCidrsOutput(ctx *Context, args *GetIsVpnGatewayAdvertisedCidrsOutputArgs, opts ...InvokeOption) GetIsVpnGatewayAdvertisedCidrsResultOutput

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

    public static class GetIsVpnGatewayAdvertisedCidrs 
    {
        public static Task<GetIsVpnGatewayAdvertisedCidrsResult> InvokeAsync(GetIsVpnGatewayAdvertisedCidrsArgs args, InvokeOptions? opts = null)
        public static Output<GetIsVpnGatewayAdvertisedCidrsResult> Invoke(GetIsVpnGatewayAdvertisedCidrsInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetIsVpnGatewayAdvertisedCidrsResult> getIsVpnGatewayAdvertisedCidrs(GetIsVpnGatewayAdvertisedCidrsArgs args, InvokeOptions options)
    public static Output<GetIsVpnGatewayAdvertisedCidrsResult> getIsVpnGatewayAdvertisedCidrs(GetIsVpnGatewayAdvertisedCidrsArgs args, InvokeOptions options)
    
    fn::invoke:
      function: ibm:index/getIsVpnGatewayAdvertisedCidrs:getIsVpnGatewayAdvertisedCidrs
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Id string
    VpnGateway string
    The VPN gateway identifier.
    VpnGatewayName string

    The VPN gateway name.

    Note Provide either one of vpn_gateway, vpn_gateway_name to identifiy vpn gateway

    Id string
    VpnGateway string
    The VPN gateway identifier.
    VpnGatewayName string

    The VPN gateway name.

    Note Provide either one of vpn_gateway, vpn_gateway_name to identifiy vpn gateway

    id String
    vpnGateway String
    The VPN gateway identifier.
    vpnGatewayName String

    The VPN gateway name.

    Note Provide either one of vpn_gateway, vpn_gateway_name to identifiy vpn gateway

    id string
    vpnGateway string
    The VPN gateway identifier.
    vpnGatewayName string

    The VPN gateway name.

    Note Provide either one of vpn_gateway, vpn_gateway_name to identifiy vpn gateway

    id str
    vpn_gateway str
    The VPN gateway identifier.
    vpn_gateway_name str

    The VPN gateway name.

    Note Provide either one of vpn_gateway, vpn_gateway_name to identifiy vpn gateway

    id String
    vpnGateway String
    The VPN gateway identifier.
    vpnGatewayName String

    The VPN gateway name.

    Note Provide either one of vpn_gateway, vpn_gateway_name to identifiy vpn gateway

    getIsVpnGatewayAdvertisedCidrs Result

    The following output properties are available:

    AdvertisedCidrs List<string>
    (List) The additional CIDRs advertised through any enabled routing protocol (for example, BGP). The routing protocol will advertise routes with these CIDRs and VPC prefixes as route destinations.
    Id string
    VpnGateway string
    VpnGatewayName string
    AdvertisedCidrs []string
    (List) The additional CIDRs advertised through any enabled routing protocol (for example, BGP). The routing protocol will advertise routes with these CIDRs and VPC prefixes as route destinations.
    Id string
    VpnGateway string
    VpnGatewayName string
    advertisedCidrs List<String>
    (List) The additional CIDRs advertised through any enabled routing protocol (for example, BGP). The routing protocol will advertise routes with these CIDRs and VPC prefixes as route destinations.
    id String
    vpnGateway String
    vpnGatewayName String
    advertisedCidrs string[]
    (List) The additional CIDRs advertised through any enabled routing protocol (for example, BGP). The routing protocol will advertise routes with these CIDRs and VPC prefixes as route destinations.
    id string
    vpnGateway string
    vpnGatewayName string
    advertised_cidrs Sequence[str]
    (List) The additional CIDRs advertised through any enabled routing protocol (for example, BGP). The routing protocol will advertise routes with these CIDRs and VPC prefixes as route destinations.
    id str
    vpn_gateway str
    vpn_gateway_name str
    advertisedCidrs List<String>
    (List) The additional CIDRs advertised through any enabled routing protocol (for example, BGP). The routing protocol will advertise routes with these CIDRs and VPC prefixes as route destinations.
    id String
    vpnGateway String
    vpnGatewayName String

    Package Details

    Repository
    ibm ibm-cloud/terraform-provider-ibm
    License
    Notes
    This Pulumi package is based on the ibm Terraform Provider.
    ibm logo
    ibm 1.86.0 published on Wednesday, Dec 3, 2025 by ibm-cloud
      Meet Neo: Your AI Platform Teammate