Created
January 31, 2020 17:55
-
-
Save adamdriscoll/0ac45603961ae9d59d5a694588726a52 to your computer and use it in GitHub Desktop.
Using a Reader AppToken in Universal Automation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[DBG]: PS C:\Users\adamr>> Get-UAScript -AppToken $AppToken.Token | |
Id : 1 | |
Name : Script.ps1 | |
Description : | |
CreatedTime : 1/31/2020 10:51:40 AM | |
ManualTime : 0 | |
CommitId : c45063d8f9f68805ffdf68231015aaaec47b13d6 | |
Content : Write-Host "Hello" | |
ScriptParameters : | |
Identity : UniversalAutomation.Identity | |
Tags : {} | |
Schedules : | |
Status : Draft | |
Folder : UniversalAutomation.Folder | |
FullPath : Script.ps1 | |
RequiredPowerShellVersion : | |
ErrorAction : Stop | |
CommitNotes : Setting script content: Script.ps1 | |
DisableManualInvocation : False | |
[DBG]: PS C:\Users\adamr>> New-UAScript -AppToken $AppToken.Token -Name 'Jeffs Script' -ScriptBlock { Get-Process } | |
New-UAScript : Call failed with status code 403 (Forbidden): POST http://localhost:10000/api/v1/Script | |
At line:1 char:1 | |
+ New-UAScript -AppToken $AppToken.Token -Name 'Jeffs Script' -ScriptBl ... | |
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | |
+ CategoryInfo : NotSpecified: (:) [New-UAScript], FlurlHttpException | |
+ FullyQualifiedErrorId : Flurl.Http.FlurlHttpException,UniversalAutomation.NewScriptCommand |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment