MCPcopy
hub / github.com/21st-dev/1code / save

Method save

src/main/lib/credential-manager.ts:97–102  ·  view source on GitHub ↗

* Save credential for a source

(source: LoadedSource, credential: StoredCredential)

Source from the content-addressed store, hash-verified

95 * Save credential for a source
96 */
97 async save(source: LoadedSource, credential: StoredCredential): Promise<void> {
98 const credentialId = this.getCredentialId(source);
99 const manager = getCredentialManager();
100 await manager.set(credentialId, credential);
101 debug(`[SourceCredentialManager] Saved ${credentialId.type} for ${source.config.slug}`);
102 }
103
104 /**
105 * Load credential for a source

Callers 8

authenticateMcpMethod · 0.95
authenticateGoogleMethod · 0.95
authenticateSlackMethod · 0.95
authenticateMicrosoftMethod · 0.95
refreshGoogleMethod · 0.95
refreshSlackMethod · 0.95
refreshMicrosoftMethod · 0.95
refreshMcpMethod · 0.95

Calls 2

getCredentialIdMethod · 0.95
setMethod · 0.45

Tested by

no test coverage detected