hsdp.getDiscoveryService
Explore with Pulumi AI
Discover standard services details
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as hsdp from "@pulumi/hsdp";
const myService = hsdp.getDiscoveryService({
name: "My Service",
});
const anotherService = hsdp.getDiscoveryService({
principal: {
username: _var.device_login,
password: _var.device_password,
oauth2ClientId: _var.mdm_oauth2_client_id,
oauth2Password: _var.mdm_oauth2_password,
},
tag: "another-service",
});
import pulumi
import pulumi_hsdp as hsdp
my_service = hsdp.get_discovery_service(name="My Service")
another_service = hsdp.get_discovery_service(principal={
"username": var["device_login"],
"password": var["device_password"],
"oauth2_client_id": var["mdm_oauth2_client_id"],
"oauth2_password": var["mdm_oauth2_password"],
},
tag="another-service")
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/hsdp/hsdp"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := hsdp.GetDiscoveryService(ctx, &hsdp.GetDiscoveryServiceArgs{
Name: pulumi.StringRef("My Service"),
}, nil)
if err != nil {
return err
}
_, err = hsdp.GetDiscoveryService(ctx, &hsdp.GetDiscoveryServiceArgs{
Principal: hsdp.GetDiscoveryServicePrincipal{
Username: pulumi.StringRef(_var.Device_login),
Password: pulumi.StringRef(_var.Device_password),
Oauth2ClientId: pulumi.StringRef(_var.Mdm_oauth2_client_id),
Oauth2Password: pulumi.StringRef(_var.Mdm_oauth2_password),
},
Tag: pulumi.StringRef("another-service"),
}, nil)
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Hsdp = Pulumi.Hsdp;
return await Deployment.RunAsync(() =>
{
var myService = Hsdp.GetDiscoveryService.Invoke(new()
{
Name = "My Service",
});
var anotherService = Hsdp.GetDiscoveryService.Invoke(new()
{
Principal = new Hsdp.Inputs.GetDiscoveryServicePrincipalInputArgs
{
Username = @var.Device_login,
Password = @var.Device_password,
Oauth2ClientId = @var.Mdm_oauth2_client_id,
Oauth2Password = @var.Mdm_oauth2_password,
},
Tag = "another-service",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.hsdp.HsdpFunctions;
import com.pulumi.hsdp.inputs.GetDiscoveryServiceArgs;
import com.pulumi.hsdp.inputs.GetDiscoveryServicePrincipalArgs;
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 myService = HsdpFunctions.getDiscoveryService(GetDiscoveryServiceArgs.builder()
.name("My Service")
.build());
final var anotherService = HsdpFunctions.getDiscoveryService(GetDiscoveryServiceArgs.builder()
.principal(GetDiscoveryServicePrincipalArgs.builder()
.username(var_.device_login())
.password(var_.device_password())
.oauth2ClientId(var_.mdm_oauth2_client_id())
.oauth2Password(var_.mdm_oauth2_password())
.build())
.tag("another-service")
.build());
}
}
variables:
myService:
fn::invoke:
function: hsdp:getDiscoveryService
arguments:
name: My Service
anotherService:
fn::invoke:
function: hsdp:getDiscoveryService
arguments:
principal:
username: ${var.device_login}
password: ${var.device_password}
oauth2ClientId: ${var.mdm_oauth2_client_id}
oauth2Password: ${var.mdm_oauth2_password}
tag: another-service
Using getDiscoveryService
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 getDiscoveryService(args: GetDiscoveryServiceArgs, opts?: InvokeOptions): Promise<GetDiscoveryServiceResult>
function getDiscoveryServiceOutput(args: GetDiscoveryServiceOutputArgs, opts?: InvokeOptions): Output<GetDiscoveryServiceResult>
def get_discovery_service(id: Optional[str] = None,
name: Optional[str] = None,
principal: Optional[GetDiscoveryServicePrincipal] = None,
tag: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetDiscoveryServiceResult
def get_discovery_service_output(id: Optional[pulumi.Input[str]] = None,
name: Optional[pulumi.Input[str]] = None,
principal: Optional[pulumi.Input[GetDiscoveryServicePrincipalArgs]] = None,
tag: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetDiscoveryServiceResult]
func GetDiscoveryService(ctx *Context, args *GetDiscoveryServiceArgs, opts ...InvokeOption) (*GetDiscoveryServiceResult, error)
func GetDiscoveryServiceOutput(ctx *Context, args *GetDiscoveryServiceOutputArgs, opts ...InvokeOption) GetDiscoveryServiceResultOutput
> Note: This function is named GetDiscoveryService
in the Go SDK.
public static class GetDiscoveryService
{
public static Task<GetDiscoveryServiceResult> InvokeAsync(GetDiscoveryServiceArgs args, InvokeOptions? opts = null)
public static Output<GetDiscoveryServiceResult> Invoke(GetDiscoveryServiceInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetDiscoveryServiceResult> getDiscoveryService(GetDiscoveryServiceArgs args, InvokeOptions options)
public static Output<GetDiscoveryServiceResult> getDiscoveryService(GetDiscoveryServiceArgs args, InvokeOptions options)
fn::invoke:
function: hsdp:index/getDiscoveryService:getDiscoveryService
arguments:
# arguments dictionary
The following arguments are supported:
- Id string
- The ID of the service
- Name string
- The name of the Service to discover
- Principal
Get
Discovery Service Principal - Tag string
The tag of the Service to discover
The current version of the Discovery service only supports
User
andDevice
principals.Service identities
are not supported (yet)
- Id string
- The ID of the service
- Name string
- The name of the Service to discover
- Principal
Get
Discovery Service Principal - Tag string
The tag of the Service to discover
The current version of the Discovery service only supports
User
andDevice
principals.Service identities
are not supported (yet)
- id String
- The ID of the service
- name String
- The name of the Service to discover
- principal
Get
Discovery Service Principal - tag String
The tag of the Service to discover
The current version of the Discovery service only supports
User
andDevice
principals.Service identities
are not supported (yet)
- id string
- The ID of the service
- name string
- The name of the Service to discover
- principal
Get
Discovery Service Principal - tag string
The tag of the Service to discover
The current version of the Discovery service only supports
User
andDevice
principals.Service identities
are not supported (yet)
- id str
- The ID of the service
- name str
- The name of the Service to discover
- principal
Get
Discovery Service Principal - tag str
The tag of the Service to discover
The current version of the Discovery service only supports
User
andDevice
principals.Service identities
are not supported (yet)
- id String
- The ID of the service
- name String
- The name of the Service to discover
- principal Property Map
- tag String
The tag of the Service to discover
The current version of the Discovery service only supports
User
andDevice
principals.Service identities
are not supported (yet)
getDiscoveryService Result
The following output properties are available:
- Actions List<string>
- (list(string)) A list of actions supported by the service
- Id string
- The ID of the service
- Is
Trusted bool - Wether this service is a trusted one
- Name string
- Tag string
- Urls List<string>
- (list(string)) The list of URLs of this service. Ordered is significant
- Principal
Get
Discovery Service Principal
- actions List<String>
- (list(string)) A list of actions supported by the service
- id String
- The ID of the service
- is
Trusted Boolean - Wether this service is a trusted one
- name String
- tag String
- urls List<String>
- (list(string)) The list of URLs of this service. Ordered is significant
- principal
Get
Discovery Service Principal
- actions Sequence[str]
- (list(string)) A list of actions supported by the service
- id str
- The ID of the service
- is_
trusted bool - Wether this service is a trusted one
- name str
- tag str
- urls Sequence[str]
- (list(string)) The list of URLs of this service. Ordered is significant
- principal
Get
Discovery Service Principal
Supporting Types
GetDiscoveryServicePrincipal
- Endpoint string
- Environment string
- Oauth2Client
Id string - The MDM OAuth2 client ID to use for token exchange
- Oauth2Password string
The MDM OAuth2 client password to use for token exchange
An
MDM OAuth2 client
with the?.?.dsc.service.readAny
set should be used for retrieving the principal token. At the time of writing this document (September 2022) you will almost certainly require aprincipal
block for correct operation of this data source- Password string
- The password of the user or device
- Region string
- Service
Id string - Service
Private stringKey - Uaa
Password string - Uaa
Username string - Username string
- The username of the user or device
- Endpoint string
- Environment string
- Oauth2Client
Id string - The MDM OAuth2 client ID to use for token exchange
- Oauth2Password string
The MDM OAuth2 client password to use for token exchange
An
MDM OAuth2 client
with the?.?.dsc.service.readAny
set should be used for retrieving the principal token. At the time of writing this document (September 2022) you will almost certainly require aprincipal
block for correct operation of this data source- Password string
- The password of the user or device
- Region string
- Service
Id string - Service
Private stringKey - Uaa
Password string - Uaa
Username string - Username string
- The username of the user or device
- endpoint String
- environment String
- oauth2Client
Id String - The MDM OAuth2 client ID to use for token exchange
- oauth2Password String
The MDM OAuth2 client password to use for token exchange
An
MDM OAuth2 client
with the?.?.dsc.service.readAny
set should be used for retrieving the principal token. At the time of writing this document (September 2022) you will almost certainly require aprincipal
block for correct operation of this data source- password String
- The password of the user or device
- region String
- service
Id String - service
Private StringKey - uaa
Password String - uaa
Username String - username String
- The username of the user or device
- endpoint string
- environment string
- oauth2Client
Id string - The MDM OAuth2 client ID to use for token exchange
- oauth2Password string
The MDM OAuth2 client password to use for token exchange
An
MDM OAuth2 client
with the?.?.dsc.service.readAny
set should be used for retrieving the principal token. At the time of writing this document (September 2022) you will almost certainly require aprincipal
block for correct operation of this data source- password string
- The password of the user or device
- region string
- service
Id string - service
Private stringKey - uaa
Password string - uaa
Username string - username string
- The username of the user or device
- endpoint str
- environment str
- oauth2_
client_ strid - The MDM OAuth2 client ID to use for token exchange
- oauth2_
password str The MDM OAuth2 client password to use for token exchange
An
MDM OAuth2 client
with the?.?.dsc.service.readAny
set should be used for retrieving the principal token. At the time of writing this document (September 2022) you will almost certainly require aprincipal
block for correct operation of this data source- password str
- The password of the user or device
- region str
- service_
id str - service_
private_ strkey - uaa_
password str - uaa_
username str - username str
- The username of the user or device
- endpoint String
- environment String
- oauth2Client
Id String - The MDM OAuth2 client ID to use for token exchange
- oauth2Password String
The MDM OAuth2 client password to use for token exchange
An
MDM OAuth2 client
with the?.?.dsc.service.readAny
set should be used for retrieving the principal token. At the time of writing this document (September 2022) you will almost certainly require aprincipal
block for correct operation of this data source- password String
- The password of the user or device
- region String
- service
Id String - service
Private StringKey - uaa
Password String - uaa
Username String - username String
- The username of the user or device
Package Details
- Repository
- hsdp philips-software/terraform-provider-hsdp
- License
- Notes
- This Pulumi package is based on the
hsdp
Terraform Provider.