-
-
Notifications
You must be signed in to change notification settings - Fork 42
Description
Description
401 on both methods
Steps To Reproduce
Get-ConfluencePage -PageId 108334572 | select -exclude body
WARNING: Confluence returned HTTP error 401 - Unauthorized
Invoke-Method : An unknown error ocurred.
At /usr/local/share/powershell/Modules/ConfluencePS/2.5.0/ConfluencePS.psm1:745 char:21
Invoke-Method @iwParameters
CategoryInfo : InvalidResult: (HTTP Status 401 – U\u2026pache Tomcat/9.0.19:String) [Invoke-Method], ArgumentException
FullyQualifiedErrorId : InvalidResponse.Status401,Invoke-Method
Set-ConfluencePage -PageId 108334572 -Body 'test' -debug
DEBUG: [Set-ConfluencePage] ParameterSetName: byParameters
DEBUG: [Set-ConfluencePage] PSBoundParameters:
Key Value
PageID 108334572
Body test
Debug True
Credential System.Management.Automation.PSCredential
ApiUri https://company/rest/api
DEBUG: [Get-Page] ParameterSetName: byId
DEBUG: [Get-Page] PSBoundParameters:
Key Value
PageID {108334572}
Credential System.Management.Automation.PSCredential
ApiUri https://company.com/rest/api
DEBUG: [Invoke-Method] ParameterSetName: __AllParameterSets
DEBUG: [Invoke-Method] PSBoundParameters:
Key Value
IncludeTotalCount False
Credential System.Management.Automation.PSCredential
Uri https://company.com/rest/api/content/108334572
Method Get
OutputType ConfluencePS.Page
Skip 0
GetParameters {expand, limit}
First 18446744073709551615
DEBUG: [Invoke-Method] Using $GetParameters:
Name Value
expand space,version,body.storage,ancestors
limit 25
DEBUG: [Invoke-Method] Executed WebRequest. Access $webResponse to see details
WARNING: Confluence returned HTTP error 401 - Unauthorized
DEBUG: [Invoke-Method] Got the following error as $responseBody
Invoke-Method : An unknown error ocurred.
At /usr/local/share/powershell/Modules/ConfluencePS/2.5.0/ConfluencePS.psm1:745 char:21
-
Invoke-Method @iwParameters -
~~~~~~~~~~~~~~~~~~~~~~~~~~~ - CategoryInfo : InvalidResult: (HTTP Status 401 – U\u2026pache Tomcat/9.0.19:String) [Invoke-Method], ArgumentException
- FullyQualifiedErrorId : InvalidResponse.Status401,Invoke-Method
The property 'Number' cannot be found on this object. Verify that the property exists and can be set.
At /usr/local/share/powershell/Modules/ConfluencePS/2.5.0/ConfluencePS.psm1:1941 char:17 - ... $Content.version.number = ++$originalPage.Version.Number
-
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - CategoryInfo : InvalidOperation: (:) [], RuntimeException
- FullyQualifiedErrorId : PropertyNotFound
DEBUG: [Set-ConfluencePage] Content to be sent:
Name Value
body {storage}
title
version {number}
ancestors {}
type page
Confirm
Are you sure you want to perform this action?
Performing the operation "Set-ConfluencePage" on target "Page ".
[Y] Yes [A] Yes to All [N] No [L] No to All [S] Suspend [?] Help (default is "Yes"): A
DEBUG: [Invoke-Method] ParameterSetName: __AllParameterSets
DEBUG: [Invoke-Method] PSBoundParameters:
Key Value
OutputType ConfluencePS.Page
Credential System.Management.Automation.PSCredential
Body {…
Method Put
Uri https://company.com/rest/api/content/108334572
DEBUG: [Invoke-Method] Executed WebRequest. Access $webResponse to see details
WARNING: Confluence returned HTTP error 401 - Unauthorized
DEBUG: [Invoke-Method] Got the following error as $responseBody
Invoke-Method : An unknown error ocurred.
At /usr/local/share/powershell/Modules/ConfluencePS/2.5.0/ConfluencePS.psm1:1963 char:13
-
Invoke-Method @iwParameters -
~~~~~~~~~~~~~~~~~~~~~~~~~~~ - CategoryInfo : InvalidResult: (HTTP Status 401 – U\u2026pache Tomcat/9.0.19:String) [Invoke-Method], ArgumentException
- FullyQualifiedErrorId : InvalidResponse.Status401,Invoke-Method
Screenshots
Your Environment
Get-Module ConfluencePS -ListAvailable | Select Name, Version
Name Version
ConfluencePS 2.5.0
ConfluencePS 2.3.6
$PSVersionTable
Name Value
PSVersion 6.2.2
PSEdition Core
GitCommitId 6.2.2
OS Darwin 18.7.0 Darwin Kernel Version 18.7.0: Thu Jun 20 18:42:21 PDT 2019; root:xnu-4903.270.47~4/RELEASE_X86_64
Platform Unix
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0