Documentation
¶
Index ¶
- func ChangelogURL(version string) string
- func CheckAuth() bool
- func CheckToken(token string) (response *sdk.UserResponse, err error)
- func Connect(token string) *sdk.Client
- func ConnectWithContext(ctx context.Context, token string) *sdk.Client
- func DisableAuthCheck(cmd *cobra.Command)
- func InvalidateToken(token string) (response *sdk.Response, err error)
- func IsAuthCheckEnabled(cmd *cobra.Command) bool
- func VersionFormat(version, buildDate string) string
- type Me
- type MeResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ChangelogURL ¶
func CheckAuth ¶
func CheckAuth() bool
CheckAuth reports whether a usable token was found in any source. config.Resolve already rejects invalid values in both positions, so this is simply "did we resolve anything" — it must not re-validate independently, or it drifts from what HasToken/Token report.
func CheckToken ¶
func CheckToken(token string) (response *sdk.UserResponse, err error)
func ConnectWithContext ¶ added in v1.0.0
ConnectWithContext is Connect with a context attached for cancellation / timeout. Prefer this in command bodies so SIGINT cleanly cancels in-flight HTTP requests rather than terminating mid-response.