Send-RDMMessage
2025-02-17
Send-RDMMessage
SYNOPSIS
Write a new secure message.
SYNTAX
NewMessage (Default)
Send-RDMMessage [-To] <PSBasicUserWrapper[]> [-Subject] <string> [[-Body] <string>]
[-Attachment <Object[]>] [-CaseSensitive] [-ExpiresIn <int>] [-ExpiresOn <datetime>]
[-ForcePromptAnswer <DialogResult[]>] [<CommonParameters>]
Reply
Send-RDMMessage [-ReplyTo] <DataSourceMessage> [[-Body] <string>] [-Subject <string>]
[-Attachment <Object[]>] [-CaseSensitive] [-ExpiresIn <int>] [-ExpiresOn <datetime>]
[-ForcePromptAnswer <DialogResult[]>] [<CommonParameters>]
ALIASES
This cmdlet has the following aliases,
DESCRIPTION
Write a message. The data source must be a Devolutions Server or Devolutions Hub Server.
EXAMPLES
EXAMPLE 1
PS C:> Send-RDMMessage 'FirstName LastName' 'ASubject' 'AMessage'
Send a secure message to 'FirstName LastName' about 'ASubject'. The detail of the message is 'AMessage'.
EXAMPLE 2
PS C:> $entryA = Get-RDMPrivateSession -Name 'entryA'; $file = New-RDMMessageAttachment -File -Path "C:\mypath\filename.extension"; Send-RDMMessage -To 'Person A', 'Person B' -Subject 'Why' -Body 'AMessage' -Attachment $entryA, $file
Fetch a private entry and create a file attachment. Send a secure message to Person A and Person B about 'Why'. The detail of the message is 'AMessage' and two attachments, 'entryA' and the file, are attached.
EXAMPLE 3
PS C:> Receive-RDMMessage -From 'First Last' -SentOn Today -Subject 'Required Connection'| Send-RDMMessage -Body 'Thank you'
Send a reply to the message 'First Last' sent today about 'Required Connection' to thank him. The subject will be 'Re: Required Connection' and the body, 'Thank you'
EXAMPLE 4
PS C:> Send-RDMMessage -To 'person A' -Subject 'ASubject' -Attachment 'anEntry' -CaseSensitive
Send a message to 'person A' with the attachment 'anEntry'. The user Person A won't be found.
EXAMPLE 5
PS C:> $entry = Get-RDMPrivateSession -Name AnEntry; Send-RDMMessage -To 'Person A' -Subject 'ASubject' -Attachment $entry
Fetch a private entry with the cmdlet Get-RDMPrivateSession. It is pointless to modify the stored entry because it will be fetched by its ID. After that, a message will be sent to Person A with the attachment AnEntry.
PARAMETERS
-Attachment
Attachments to add to the message. The supported types are PSMessageAttachment and PSConnection.
Type: System.Object[]
DefaultValue: ''
SupportsWildcards: false
ParameterValue: []
Aliases: []
ParameterSets:
- Name: (All)
Position: Named
IsRequired: false
ValueFromPipeline: false
ValueFromPipelineByPropertyName: false
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
-Body
Body text of the message.
Type: System.String
DefaultValue: ''
SupportsWildcards: false
ParameterValue: []
Aliases: []
ParameterSets:
- Name: NewMessage
Position: 3
IsRequired: false
ValueFromPipeline: false
ValueFromPipelineByPropertyName: true
ValueFromRemainingArguments: false
- Name: Reply
Position: 2
IsRequired: false
ValueFromPipeline: false
ValueFromPipelineByPropertyName: true
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
-CaseSensitive
The value passed for the user will be case sensitive.
Type: System.Management.Automation.SwitchParameter
DefaultValue: ''
SupportsWildcards: false
ParameterValue: []
Aliases: []
ParameterSets:
- Name: (All)
Position: Named
IsRequired: false
ValueFromPipeline: false
ValueFromPipelineByPropertyName: false
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
-ExpiresIn
Number of days before the message expires.
Type: System.Nullable`1[System.Int32]
DefaultValue: ''
SupportsWildcards: false
ParameterValue: []
Aliases: []
ParameterSets:
- Name: (All)
Position: Named
IsRequired: false
ValueFromPipeline: false
ValueFromPipelineByPropertyName: false
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
-ExpiresOn
Date when the message will expire.
Type: System.Nullable`1[System.DateTime]
DefaultValue: ''
SupportsWildcards: false
ParameterValue: []
Aliases: []
ParameterSets:
- Name: (All)
Position: Named
IsRequired: false
ValueFromPipeline: false
ValueFromPipelineByPropertyName: false
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
-ForcePromptAnswer
Switch to use with caution. It will automatically answer prompt asking yes/no, yes/no/cancel, or ok/cancel questions. In case of multiple prompts, multiple values can be passed to this parameter. Here are the accepted values:
- Yes: Accept the prompt. Cover the OK and Automatic value.
- No: Refuse the yes/no/cancel prompt. Cancel is the fallback option if there is not an option No.
- Cancel: Cancel the yes/no/cancel prompt. No is the fallback option if there is not an option Cancel.
Type: System.Windows.Forms.DialogResult[]
DefaultValue: ''
SupportsWildcards: false
ParameterValue: []
Aliases: []
ParameterSets:
- Name: (All)
Position: Named
IsRequired: false
ValueFromPipeline: false
ValueFromPipelineByPropertyName: false
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
-ReplyTo
The subject and a recipient will be added based on the message. The subject can be modified with the Subject parameter.
Type: Devolutions.RemoteDesktopManager.Business.Messages.DataSourceMessage
DefaultValue: ''
SupportsWildcards: false
ParameterValue: []
Aliases: []
ParameterSets:
- Name: Reply
Position: 1
IsRequired: true
ValueFromPipeline: true
ValueFromPipelineByPropertyName: true
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
-Subject
Subject of the message.
Type: System.String
DefaultValue: ''
SupportsWildcards: false
ParameterValue: []
Aliases: []
ParameterSets:
- Name: NewMessage
Position: 2
IsRequired: true
ValueFromPipeline: false
ValueFromPipelineByPropertyName: true
ValueFromRemainingArguments: false
- Name: Reply
Position: Named
IsRequired: false
ValueFromPipeline: false
ValueFromPipelineByPropertyName: true
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
-To
The recepients of the message. They can be identified by ID, name, email, or by their PSUserInfo.
Type: RemoteDesktopManager.PowerShellModule.PSOutputObject.PSWrapper.PSBasicUserWrapper[]
DefaultValue: ''
SupportsWildcards: false
ParameterValue: []
Aliases: []
ParameterSets:
- Name: NewMessage
Position: 1
IsRequired: true
ValueFromPipeline: false
ValueFromPipelineByPropertyName: true
ValueFromRemainingArguments: false
DontShow: false
AcceptedValues: []
HelpMessage: ''
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.
INPUTS
Devolutions.RemoteDesktopManager.Business.Messages.DataSourceMessage
The message obtained from the Receive-RDMMessage can be piped to the parameter ReplyTo.
RemoteDesktopManager.PowerShellModule.PSOutputObject.PSWrapper.PSBasicUserWrapper
System.String
OUTPUTS
NOTES
For more information, type "Get-Help Send-RDMMessage -detailed". For technical information, type "Get-Help Send-RDMMessage -full".