package
1.3.2
Repository: https://github.com/spacelift-io/spacectl.git
Documentation: pkg.go.dev

# Functions

Defaults returns default context and HTTP client to use by clients that don't need any further configuration.
FromAPIKey builds a Spacelift session from a combination of endpoint, API key ID and API key secret.
FromAPIToken creates a session from a ready API token.
FromCurrentProfile creates a session from credentials stored in the currently selected profile.
FromEnvironment creates a Spacelift session from the environment.
FromGitHubToken builds a Spacelift session from a combination of endpoint, and a GitHub access token.
Must provides a helper that either creates a Session or dies trying.
New creates a session using the default chain of credentials sources: first the environment, then the current credentials file.
NewProfileManager creates a new ProfileManager using the specified directory to store the profile data.
UserProfileManager creates a new ProfileManager using the user home directory to store the profile data.

# Constants

ConfigFileName is the name of the file containing the spacectl config.
CredentialsTypeAPIKey represents credentials stored as an API key id-secret pair.
CredentialsTypeAPIToken represents credentials stored as a JWT access token.
CredentialsTypeGitHubToken represents credentials stored as a GitHub access token.
CredentialsTypeInvalid represents an invalid zero value for the CredentialsType.
EnvSpaceliftAPIEndpoint represents the name of the environment variable pointing to the Spacelift API endpoint.
#nosec G101.
nolint: gosec.
nolint: gosec.
#nosec G101.
#nosec G101.
SpaceliftConfigDirectory is the name of the Spacelift config directory.

# Structs

A Profile represents a spacectl profile which is used to store credential information for accessing Spacelift.
A ProfileManager is used to interact with Spacelift profiles.
StoredCredentials is a filesystem representation of the credentials.

# Interfaces

Session is an abstraction around session creation based on credentials from various sources.

# Type aliases

CredentialsType represents the type of credentials being used.