1. Packages
  2. Cisco Catalyst SD-WAN
  3. API Docs
  4. getDevice
Cisco Catalyst SD-WAN v0.1.1 published on Friday, May 31, 2024 by Pulumi

sdwan.getDevice

Explore with Pulumi AI

sdwan logo
Cisco Catalyst SD-WAN v0.1.1 published on Friday, May 31, 2024 by Pulumi

    This data source can read the Device .

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as sdwan from "@pulumi/sdwan";
    
    const example = sdwan.getDevice({
        serialNumber: "3FFEFB37892E415FAF34A95D2328EC4C",
        name: "Controller01",
    });
    
    import pulumi
    import pulumi_sdwan as sdwan
    
    example = sdwan.get_device(serial_number="3FFEFB37892E415FAF34A95D2328EC4C",
        name="Controller01")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-sdwan/sdk/go/sdwan"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := sdwan.GetDevice(ctx, &sdwan.GetDeviceArgs{
    			SerialNumber: pulumi.StringRef("3FFEFB37892E415FAF34A95D2328EC4C"),
    			Name:         pulumi.StringRef("Controller01"),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Sdwan = Pulumi.Sdwan;
    
    return await Deployment.RunAsync(() => 
    {
        var example = Sdwan.GetDevice.Invoke(new()
        {
            SerialNumber = "3FFEFB37892E415FAF34A95D2328EC4C",
            Name = "Controller01",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.sdwan.SdwanFunctions;
    import com.pulumi.sdwan.inputs.GetDeviceArgs;
    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 = SdwanFunctions.getDevice(GetDeviceArgs.builder()
                .serialNumber("3FFEFB37892E415FAF34A95D2328EC4C")
                .name("Controller01")
                .build());
    
        }
    }
    
    variables:
      example:
        fn::invoke:
          Function: sdwan:getDevice
          Arguments:
            serialNumber: 3FFEFB37892E415FAF34A95D2328EC4C
            name: Controller01
    

    Using getDevice

    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 getDevice(args: GetDeviceArgs, opts?: InvokeOptions): Promise<GetDeviceResult>
    function getDeviceOutput(args: GetDeviceOutputArgs, opts?: InvokeOptions): Output<GetDeviceResult>
    def get_device(name: Optional[str] = None,
                   serial_number: Optional[str] = None,
                   opts: Optional[InvokeOptions] = None) -> GetDeviceResult
    def get_device_output(name: Optional[pulumi.Input[str]] = None,
                   serial_number: Optional[pulumi.Input[str]] = None,
                   opts: Optional[InvokeOptions] = None) -> Output[GetDeviceResult]
    func GetDevice(ctx *Context, args *GetDeviceArgs, opts ...InvokeOption) (*GetDeviceResult, error)
    func GetDeviceOutput(ctx *Context, args *GetDeviceOutputArgs, opts ...InvokeOption) GetDeviceResultOutput

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

    public static class GetDevice 
    {
        public static Task<GetDeviceResult> InvokeAsync(GetDeviceArgs args, InvokeOptions? opts = null)
        public static Output<GetDeviceResult> Invoke(GetDeviceInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetDeviceResult> getDevice(GetDeviceArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: sdwan:index/getDevice:getDevice
      arguments:
        # arguments dictionary

    The following arguments are supported:

    Name string
    The hostname of a device
    SerialNumber string
    Serial number for device. Could be board or virtual identifier
    Name string
    The hostname of a device
    SerialNumber string
    Serial number for device. Could be board or virtual identifier
    name String
    The hostname of a device
    serialNumber String
    Serial number for device. Could be board or virtual identifier
    name string
    The hostname of a device
    serialNumber string
    Serial number for device. Could be board or virtual identifier
    name str
    The hostname of a device
    serial_number str
    Serial number for device. Could be board or virtual identifier
    name String
    The hostname of a device
    serialNumber String
    Serial number for device. Could be board or virtual identifier

    getDevice Result

    The following output properties are available:

    Devices List<GetDeviceDevice>
    List of returned devices
    Id string
    The id of the object
    Name string
    The hostname of a device
    SerialNumber string
    Serial number for device. Could be board or virtual identifier
    Devices []GetDeviceDevice
    List of returned devices
    Id string
    The id of the object
    Name string
    The hostname of a device
    SerialNumber string
    Serial number for device. Could be board or virtual identifier
    devices List<GetDeviceDevice>
    List of returned devices
    id String
    The id of the object
    name String
    The hostname of a device
    serialNumber String
    Serial number for device. Could be board or virtual identifier
    devices GetDeviceDevice[]
    List of returned devices
    id string
    The id of the object
    name string
    The hostname of a device
    serialNumber string
    Serial number for device. Could be board or virtual identifier
    devices Sequence[GetDeviceDevice]
    List of returned devices
    id str
    The id of the object
    name str
    The hostname of a device
    serial_number str
    Serial number for device. Could be board or virtual identifier
    devices List<Property Map>
    List of returned devices
    id String
    The id of the object
    name String
    The hostname of a device
    serialNumber String
    Serial number for device. Could be board or virtual identifier

    Supporting Types

    GetDeviceDevice

    DeviceId string
    The device ID as defined in SD-WAN Manager
    Hostname string
    Hostname for respective device
    Reachability string
    Reachability of device
    SerialNumber string
    Serial number for device. Could be board or virtual identifier
    SiteId string
    Site id for respective device
    State string
    State for respective device
    Status string
    Status for respective device
    Uuid string
    Unique identifier for device
    DeviceId string
    The device ID as defined in SD-WAN Manager
    Hostname string
    Hostname for respective device
    Reachability string
    Reachability of device
    SerialNumber string
    Serial number for device. Could be board or virtual identifier
    SiteId string
    Site id for respective device
    State string
    State for respective device
    Status string
    Status for respective device
    Uuid string
    Unique identifier for device
    deviceId String
    The device ID as defined in SD-WAN Manager
    hostname String
    Hostname for respective device
    reachability String
    Reachability of device
    serialNumber String
    Serial number for device. Could be board or virtual identifier
    siteId String
    Site id for respective device
    state String
    State for respective device
    status String
    Status for respective device
    uuid String
    Unique identifier for device
    deviceId string
    The device ID as defined in SD-WAN Manager
    hostname string
    Hostname for respective device
    reachability string
    Reachability of device
    serialNumber string
    Serial number for device. Could be board or virtual identifier
    siteId string
    Site id for respective device
    state string
    State for respective device
    status string
    Status for respective device
    uuid string
    Unique identifier for device
    device_id str
    The device ID as defined in SD-WAN Manager
    hostname str
    Hostname for respective device
    reachability str
    Reachability of device
    serial_number str
    Serial number for device. Could be board or virtual identifier
    site_id str
    Site id for respective device
    state str
    State for respective device
    status str
    Status for respective device
    uuid str
    Unique identifier for device
    deviceId String
    The device ID as defined in SD-WAN Manager
    hostname String
    Hostname for respective device
    reachability String
    Reachability of device
    serialNumber String
    Serial number for device. Could be board or virtual identifier
    siteId String
    Site id for respective device
    state String
    State for respective device
    status String
    Status for respective device
    uuid String
    Unique identifier for device

    Package Details

    Repository
    sdwan pulumi/pulumi-sdwan
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the sdwan Terraform Provider.
    sdwan logo
    Cisco Catalyst SD-WAN v0.1.1 published on Friday, May 31, 2024 by Pulumi