MCPcopy Create free account
hub / github.com/basecamp/hey-cli / Load

Method Load

internal/auth/store.go:65–71  ·  view source on GitHub ↗

Load retrieves credentials for the given origin.

(origin string)

Source from the content-addressed store, hash-verified

63
64// Load retrieves credentials for the given origin.
65func (s *Store) Load(origin string) (*Credentials, error) {
66 s.ensureInit()
67 if s.useKeyring {
68 return s.loadFromKeyring(origin)
69 }
70 return s.loadFromFile(origin)
71}
72
73// Save stores credentials for the given origin.
74func (s *Store) Save(origin string, creds *Credentials) error {

Callers 13

TestSaveLoadRoundTripFunction · 0.80
TestLoadNotFoundFunction · 0.80
TestDeleteCredentialsFunction · 0.80
TestMultipleOriginsFunction · 0.80
AccessTokenMethod · 0.80
AuthenticateRequestMethod · 0.80
IsAuthenticatedMethod · 0.80
RefreshMethod · 0.80
newAuthStatusCommandFunction · 0.80
migrateOldCredentialsFunction · 0.80
runDoctorChecksFunction · 0.80
RequestCountMethod · 0.80

Calls 3

ensureInitMethod · 0.95
loadFromKeyringMethod · 0.95
loadFromFileMethod · 0.95

Tested by 4

TestSaveLoadRoundTripFunction · 0.64
TestLoadNotFoundFunction · 0.64
TestDeleteCredentialsFunction · 0.64
TestMultipleOriginsFunction · 0.64