spws • Docs
spws / getCurrentUser
getCurrentUser(
__namedParameters
):Promise
<Operation
>
Gets the current authenticated user.
• __namedParameters = {}
• __namedParameters.getFromWindow?: boolean
= true
If false, the user ID will be scraped from a SharePoint page
• __namedParameters.ID?: string
The user ID. If defined, the page scrape is skipped and user info is returned
This is useful for testing as scraping pages is flaky
• __namedParameters.webURL?: string
= defaults.webURL
The SharePoint web URL
Promise
<Operation
>
Authentication can be changed using a proxy server and supplying a username and password. This is not recommended and should be used for testing purposes only.