I am trying to do a simple invoke rest method request for my API Authentication, however the bearer token is displaying a truncated output. How do I display the output string entirely?
PS C:\WINDOWS\system32> Invoke-RestMethod -Method POST -Body $body -uri $uri
access_token
------------
gAAAAMAEzhS8pzLrV5I1d5CJuyLq0BbBHaBAFhLzs9Uqk3zUueEvyxJ3NQN5KrTpexrFi7aUYbgvDzA0nQf7caGddeIngxC0uGjpVBlT5AlHbddwDiQhb4Ruh2BQry9dhmzN47Mz840FAU8WOrtQNXEundiaaN30nqel2365TEZc1uU15AIAAIAAAAAc_fYAsOVgvBOlg7QKGxgMbewrxaav-eprjqci9mCFQtfke...
I have tried addting the Out-String on the end but it shows me this error:
Invoke-RestMethod : A positional parameter cannot be found that accepts argument 'Out-String'.
At line:1 char:1
+ Invoke-RestMethod -Method POST -Body $body -uri $uri Out-String -Widt ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidArgument: (:) [Invoke-RestMethod], ParameterBindingException
+ FullyQualifiedErrorId : PositionalParameterNotFound,Microsoft.PowerShell.Commands.InvokeRestMethodCommand