zia logo
Zscaler Internet Access v0.0.3, Jan 30 23

zia.Devices.getDevices

Use the zia_devices data source to get information about a device in the Zscaler Internet Access cloud or via the API. This data source can then be associated with resources such as: URL Filtering Rules

Example Usage

using System.Collections.Generic;
using Pulumi;
using Zia = Pulumi.Zia;

return await Deployment.RunAsync(() => 
{
    var device = Zia.Devices.GetDevices.Invoke(new()
    {
        Name = "administrator",
    });

});
package main

import (
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
	"github.com/zscaler/pulumi-zia/sdk/go/zia/Devices"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := Devices.GetDevices(ctx, &devices.GetDevicesArgs{
			Name: pulumi.StringRef("administrator"),
		}, 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.zia.Devices.DevicesFunctions;
import com.pulumi.zia.Devices.inputs.GetDevicesArgs;
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 device = DevicesFunctions.getDevices(GetDevicesArgs.builder()
            .name("administrator")
            .build());

    }
}
import pulumi
import pulumi_zia as zia

device = zia.Devices.get_devices(name="administrator")
import * as pulumi from "@pulumi/pulumi";
import * as zia from "@pulumi/zia";

const device = zia.Devices.getDevices({
    name: "administrator",
});
variables:
  device:
    fn::invoke:
      Function: zia:Devices:getDevices
      Arguments:
        name: administrator

Using getDevices

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 getDevices(args: GetDevicesArgs, opts?: InvokeOptions): Promise<GetDevicesResult>
function getDevicesOutput(args: GetDevicesOutputArgs, opts?: InvokeOptions): Output<GetDevicesResult>
def get_devices(device_group_type: Optional[str] = None,
                device_model: Optional[str] = None,
                name: Optional[str] = None,
                os_type: Optional[str] = None,
                os_version: Optional[str] = None,
                owner_name: Optional[str] = None,
                opts: Optional[InvokeOptions] = None) -> GetDevicesResult
def get_devices_output(device_group_type: Optional[pulumi.Input[str]] = None,
                device_model: Optional[pulumi.Input[str]] = None,
                name: Optional[pulumi.Input[str]] = None,
                os_type: Optional[pulumi.Input[str]] = None,
                os_version: Optional[pulumi.Input[str]] = None,
                owner_name: Optional[pulumi.Input[str]] = None,
                opts: Optional[InvokeOptions] = None) -> Output[GetDevicesResult]
func GetDevices(ctx *Context, args *GetDevicesArgs, opts ...InvokeOption) (*GetDevicesResult, error)
func GetDevicesOutput(ctx *Context, args *GetDevicesOutputArgs, opts ...InvokeOption) GetDevicesResultOutput

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

public static class GetDevices 
{
    public static Task<GetDevicesResult> InvokeAsync(GetDevicesArgs args, InvokeOptions? opts = null)
    public static Output<GetDevicesResult> Invoke(GetDevicesInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetDevicesResult> getDevices(GetDevicesArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
  function: zia:Devices/getDevices:getDevices
  arguments:
    # arguments dictionary

The following arguments are supported:

DeviceGroupType string

(String) The device group type. i.e ZCC_OS, NON_ZCC, CBI

DeviceModel string

(String) The device model.

Name string

The name of the devices to be exported.

OsType string

(String) The operating system (OS). ANY, OTHER_OS, IOS, ANDROID_OS, WINDOWS_OS, MAC_OS, LINUX

OsVersion string

(String) The operating system version.

OwnerName string

(String) The device owner's user name.

DeviceGroupType string

(String) The device group type. i.e ZCC_OS, NON_ZCC, CBI

DeviceModel string

(String) The device model.

Name string

The name of the devices to be exported.

OsType string

(String) The operating system (OS). ANY, OTHER_OS, IOS, ANDROID_OS, WINDOWS_OS, MAC_OS, LINUX

OsVersion string

(String) The operating system version.

OwnerName string

(String) The device owner's user name.

deviceGroupType String

(String) The device group type. i.e ZCC_OS, NON_ZCC, CBI

deviceModel String

(String) The device model.

name String

The name of the devices to be exported.

osType String

(String) The operating system (OS). ANY, OTHER_OS, IOS, ANDROID_OS, WINDOWS_OS, MAC_OS, LINUX

osVersion String

(String) The operating system version.

ownerName String

(String) The device owner's user name.

deviceGroupType string

(String) The device group type. i.e ZCC_OS, NON_ZCC, CBI

deviceModel string

(String) The device model.

name string

The name of the devices to be exported.

osType string

(String) The operating system (OS). ANY, OTHER_OS, IOS, ANDROID_OS, WINDOWS_OS, MAC_OS, LINUX

osVersion string

(String) The operating system version.

ownerName string

(String) The device owner's user name.

device_group_type str

(String) The device group type. i.e ZCC_OS, NON_ZCC, CBI

device_model str

(String) The device model.

name str

The name of the devices to be exported.

os_type str

(String) The operating system (OS). ANY, OTHER_OS, IOS, ANDROID_OS, WINDOWS_OS, MAC_OS, LINUX

os_version str

(String) The operating system version.

owner_name str

(String) The device owner's user name.

deviceGroupType String

(String) The device group type. i.e ZCC_OS, NON_ZCC, CBI

deviceModel String

(String) The device model.

name String

The name of the devices to be exported.

osType String

(String) The operating system (OS). ANY, OTHER_OS, IOS, ANDROID_OS, WINDOWS_OS, MAC_OS, LINUX

osVersion String

(String) The operating system version.

ownerName String

(String) The device owner's user name.

getDevices Result

The following output properties are available:

Description string

(String) The device's description.

DeviceGroupType string

(String) The device group type. i.e ZCC_OS, NON_ZCC, CBI

DeviceModel string

(String) The device model.

Id int

(String) The unique identifer for the device group.

Name string

(String) The device name.

OsType string

(String) The operating system (OS). ANY, OTHER_OS, IOS, ANDROID_OS, WINDOWS_OS, MAC_OS, LINUX

OsVersion string

(String) The operating system version.

OwnerName string

(String) The device owner's user name.

OwnerUserId int

(int) The unique identifier of the device owner (i.e., user).

Description string

(String) The device's description.

DeviceGroupType string

(String) The device group type. i.e ZCC_OS, NON_ZCC, CBI

DeviceModel string

(String) The device model.

Id int

(String) The unique identifer for the device group.

Name string

(String) The device name.

OsType string

(String) The operating system (OS). ANY, OTHER_OS, IOS, ANDROID_OS, WINDOWS_OS, MAC_OS, LINUX

OsVersion string

(String) The operating system version.

OwnerName string

(String) The device owner's user name.

OwnerUserId int

(int) The unique identifier of the device owner (i.e., user).

description String

(String) The device's description.

deviceGroupType String

(String) The device group type. i.e ZCC_OS, NON_ZCC, CBI

deviceModel String

(String) The device model.

id Integer

(String) The unique identifer for the device group.

name String

(String) The device name.

osType String

(String) The operating system (OS). ANY, OTHER_OS, IOS, ANDROID_OS, WINDOWS_OS, MAC_OS, LINUX

osVersion String

(String) The operating system version.

ownerName String

(String) The device owner's user name.

ownerUserId Integer

(int) The unique identifier of the device owner (i.e., user).

description string

(String) The device's description.

deviceGroupType string

(String) The device group type. i.e ZCC_OS, NON_ZCC, CBI

deviceModel string

(String) The device model.

id number

(String) The unique identifer for the device group.

name string

(String) The device name.

osType string

(String) The operating system (OS). ANY, OTHER_OS, IOS, ANDROID_OS, WINDOWS_OS, MAC_OS, LINUX

osVersion string

(String) The operating system version.

ownerName string

(String) The device owner's user name.

ownerUserId number

(int) The unique identifier of the device owner (i.e., user).

description str

(String) The device's description.

device_group_type str

(String) The device group type. i.e ZCC_OS, NON_ZCC, CBI

device_model str

(String) The device model.

id int

(String) The unique identifer for the device group.

name str

(String) The device name.

os_type str

(String) The operating system (OS). ANY, OTHER_OS, IOS, ANDROID_OS, WINDOWS_OS, MAC_OS, LINUX

os_version str

(String) The operating system version.

owner_name str

(String) The device owner's user name.

owner_user_id int

(int) The unique identifier of the device owner (i.e., user).

description String

(String) The device's description.

deviceGroupType String

(String) The device group type. i.e ZCC_OS, NON_ZCC, CBI

deviceModel String

(String) The device model.

id Number

(String) The unique identifer for the device group.

name String

(String) The device name.

osType String

(String) The operating system (OS). ANY, OTHER_OS, IOS, ANDROID_OS, WINDOWS_OS, MAC_OS, LINUX

osVersion String

(String) The operating system version.

ownerName String

(String) The device owner's user name.

ownerUserId Number

(int) The unique identifier of the device owner (i.e., user).

Package Details

Repository
zia zscaler/pulumi-zia
License
MIT
Notes

This Pulumi package is based on the zia Terraform Provider.