Connect-MQTTBroker
SYNOPSIS
SYNTAX
Anon (Default)
Connect-MQTTBroker -Hostname <String> [-Port <Int32>] [-TLS] [-ProgressAction <ActionPreference>]
[<CommonParameters>]
Auth
Connect-MQTTBroker -Hostname <String> [-Port <Int32>] -Username <String> -Password <SecureString> [-TLS]
[-ProgressAction <ActionPreference>] [<CommonParameters>]
DESCRIPTION
This function establishes a session with the MQTT broker and returns a session object that should then be passed along when using other cmdlets.
EXAMPLES
EXAMPLE 1
$Session = Connect-MQTTBroker -Hostname mqttbroker.contoso.com -Port 1234 -Username mqttuser -Password (ConvertTo-SecureString -String 'P@ssw0rd1' -AsPlainText -Force)
Establish a MQTT Broker session with authentication
EXAMPLE 2
$Session = Connect-MQTTBroker -Hostname mqttbroker.contoso.com -Port 1234
Establish a MQTT Broker session without authentication
PARAMETERS
-Hostname
Defines the hostname of the MQTT Broker to connect to
Type: String
Parameter Sets: (All)
Aliases:
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-Port
Defines the port of the MQTT Broker. Defaults to 1883.
Type: Int32
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: 0
Accept pipeline input: False
Accept wildcard characters: False
-Username
Defines the username to use when connecting to the MQTT broker
Type: String
Parameter Sets: Auth
Aliases:
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-Password
Defines the password (securestring) to use when connecting to the MQTT Broker
Type: SecureString
Parameter Sets: Auth
Aliases:
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
-TLS
Defines if the connection should be encrypted
Type: SwitchParameter
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: False
Accept pipeline input: False
Accept wildcard characters: False
-ProgressAction
{{ Fill ProgressAction Description }}
Type: ActionPreference
Parameter Sets: (All)
Aliases: proga
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.
INPUTS
OUTPUTS
NOTES
RELATED LINKS
EDIT THIS DOC
This page was auto-generated from the powershell command comment based help. To edit the content of this page, update the script file comment based help on github Github