spacecode 2.0.0 → 2.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/mcp/index.js CHANGED
@@ -1021,6 +1021,7 @@ var config_exports = {};
1021
1021
  __export(config_exports, {
1022
1022
  addTask: () => addTask,
1023
1023
  addTasks: () => addTasks,
1024
+ applyApiKeyFlag: () => applyApiKeyFlag,
1024
1025
  cancelTask: () => cancelTask,
1025
1026
  clearAuth: () => clearAuth,
1026
1027
  getConfigDir: () => getConfigDir,
@@ -1273,6 +1274,9 @@ async function clearAuth() {
1273
1274
  }
1274
1275
  }
1275
1276
  }
1277
+ function applyApiKeyFlag(key) {
1278
+ if (key?.startsWith("sk_")) process.env.SPACECODE_TOKEN = key;
1279
+ }
1276
1280
  async function resolveAuthToken() {
1277
1281
  const envToken = process.env.SPACECODE_TOKEN;
1278
1282
  if (envToken) {