Running from a web page or the terminal I get this error:
PS /home/data/Repository> Send-PSUEvent -hub eventhub -computername fc6f3e7343f0 -data “foo” -verbose
[ERROR] Data at the root level is invalid. Line 1, position 1.
PS /home/data/Repository> $error[0].exception
LineNumber : 1
LinePosition : 1
SourceUri :
Message : Data at the root level is invalid. Line 1, position 1.
TargetSite : Void Throw(System.Exception)
Data : {}
InnerException :
HelpLink :
Source : System.Private.Xml
HResult : -2146232000
StackTrace : at System.Xml.XmlTextReaderImpl.Throw(Exception e)
at System.Xml.XmlTextReaderImpl.Throw(String res, String arg)
at System.Xml.XmlTextReaderImpl.ParseRootLevelWhitespace()
at System.Xml.XmlTextReaderImpl.ParseDocumentContent()
at System.Management.Automation.Deserializer.Start()
at System.Management.Automation.Deserializer…ctor(XmlReader reader, DeserializationContext context)
at System.Management.Automation.PSSerializer.DeserializeAsList(String source)
at System.Management.Automation.PSSerializer.Deserialize(String source)
at PowerShellUniversal.SendEventCommand.ProcessRecord() in C:\actions-runner_work\universal\universal\src\Cmdlets\Apis\SendEventCommand.cs:line 28
at System.Management.Automation.CommandProcessor.ProcessRecord()
Product: PowerShell Universal
Version: 1.4.6