Skip to content

Get‑ShpContext

Raimund edited this page Aug 26, 2026 · 2 revisions

SYNOPSIS

Returns the current ShellPilot session context (connection options).

SYNTAX

Get-ShpContext [<CommonParameters>]

DESCRIPTION

Reads the module-scoped session context set by Set-ShpContext and returns it as an object. These connection-level options (HTTP timeout, retry behaviour, an optional alternative backend, and an optional in-memory GitHub OAuth token) are applied by Invoke-Shp and the other API cmdlets when the matching parameter is not supplied on the call. A value of $null means no override is set and the built-in default is used. The ApiKey and the GitHubToken are masked so neither is ever echoed. The context lives only in the current PowerShell session.

EXAMPLES

EXAMPLE 1

Get-ShpContext

Shows the connection options currently in effect for the session.

PARAMETERS

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

INPUTS

OUTPUTS

System.Management.Automation.PSCustomObject

An object with TimeoutSec, MaxRetryCount, RetryDelaySec,

NetworkOutageToleranceSec, ApiBase, a masked ApiKey indicator, and a

masked GitHubToken indicator.

NOTES

RELATED LINKS

Set-ShpContext

Clear-ShpContext

Clone this wiki locally