< Back

New-NexusApiHeader

Sat Jan 18, 2020 5:16 pm

NAME New-NexusApiHeader



SYNOPSIS

Creates the web request header to access the Nexus Api.





SYNTAX

New-NexusApiHeader [-Credential] <PSCredential> [<CommonParameters>]





DESCRIPTION

Creates the web request header to access the Nexus Api.





PARAMETERS

-Credential <PSCredential>

Credentials used to access Nexus.



Required? true

Position? 1

Default value

Accept pipeline input? false

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS



OUTPUTS



NOTES





The basic code of this function was borrowed from the chocolatey-nexus-repo package

(https://chocolatey.org/packages/chocolatey-nexus-repo). Credit to Stephen Valdinger and Paul Broadwith.



-------------------------- EXAMPLE 1 --------------------------



PS C:\\>$creds = Get-Credential



New-Nexus-ApiHeader -Credential $creds



Creates a new header with the credential $creds to access the Nexus Api.











RELATED LINKS

https://github.com/pauby/NexusManagemen ... iHeader.md