ns1.getNetworks
Explore with Pulumi AI
Provides details about NS1 Networks. Use this if you would simply like to read information from NS1 into your configurations. For read/write operations, you should use a resource.
Example Usage
using System.Collections.Generic;
using Pulumi;
using Ns1 = Pulumi.Ns1;
return await Deployment.RunAsync(() =>
{
var example = Ns1.GetNetworks.Invoke();
});
package main
import (
"github.com/pulumi/pulumi-ns1/sdk/v3/go/ns1"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := ns1.GetNetworks(ctx, nil, nil)
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.ns1.Ns1Functions;
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 = Ns1Functions.getNetworks();
}
}
import pulumi
import pulumi_ns1 as ns1
example = ns1.get_networks()
import * as pulumi from "@pulumi/pulumi";
import * as ns1 from "@pulumi/ns1";
const example = ns1.getNetworks({});
variables:
example:
fn::invoke:
Function: ns1:getNetworks
Arguments: {}
Using getNetworks
function getNetworks(opts?: InvokeOptions): Promise<GetNetworksResult>
def get_networks(opts: Optional[InvokeOptions] = None) -> GetNetworksResult
func GetNetworks(ctx *Context, opts ...InvokeOption) (*GetNetworksResult, error)
> Note: This function is named GetNetworks
in the Go SDK.
public static class GetNetworks
{
public static Task<GetNetworksResult> InvokeAsync(InvokeOptions? opts = null)
}
public static CompletableFuture<GetNetworksResult> getNetworks(InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: ns1:index/getNetworks:getNetworks
arguments:
# arguments dictionary
getNetworks Result
The following output properties are available:
- Id string
The provider-assigned unique ID for this managed resource.
- Networks
List<Get
Networks Network> A set of the available networks. Networks is documented below.
- Id string
The provider-assigned unique ID for this managed resource.
- Networks
[]Get
Networks Network A set of the available networks. Networks is documented below.
- id String
The provider-assigned unique ID for this managed resource.
- networks
List<Get
Networks Network> A set of the available networks. Networks is documented below.
- id string
The provider-assigned unique ID for this managed resource.
- networks
Get
Networks Network[] A set of the available networks. Networks is documented below.
- id str
The provider-assigned unique ID for this managed resource.
- networks
Sequence[Get
Networks Network] A set of the available networks. Networks is documented below.
- id String
The provider-assigned unique ID for this managed resource.
- networks List<Property Map>
A set of the available networks. Networks is documented below.
Supporting Types
GetNetworksNetwork
- label str
Label associated with the network.
- name str
Name of the network.
- network_
id int network ID (
int
). Default is network 0, the primary NS1 Managed DNS Network.
Package Details
- Repository
- NS1 pulumi/pulumi-ns1
- License
- Apache-2.0
- Notes
This Pulumi package is based on the
ns1
Terraform Provider.