@oda-agent/openclaw-plugin 0.5.0 → 0.6.1

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.
@@ -1 +1 @@
1
- {"version":3,"file":"credentials.d.ts","sourceRoot":"","sources":["../src/credentials.ts"],"names":[],"mappings":";AAAA,MAAM,WAAW,iBAAiB;IAChC,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,eAAO,MAAM,iBAAiB,cAAc,CAAC;AAC7C,eAAO,MAAM,oBAAoB,iBAAiB,CAAC;AAOnD,wBAAgB,0BAA0B,CAAC,GAAG,GAAE,MAAM,CAAC,UAA8B,GAAG,iBAAiB,CAYxG"}
1
+ {"version":3,"file":"credentials.d.ts","sourceRoot":"","sources":["../src/credentials.ts"],"names":[],"mappings":";AAAA,MAAM,WAAW,iBAAiB;IAChC,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,eAAO,MAAM,iBAAiB,cAAc,CAAC;AAC7C,eAAO,MAAM,oBAAoB,iBAAiB,CAAC;AAOnD,wBAAgB,0BAA0B,CAAC,GAAG,GAAE,MAAM,CAAC,UAAwB,GAAG,iBAAiB,CAclG"}
@@ -7,9 +7,11 @@ function readEnvironmentValue(env, name) {
7
7
  const value = env?.[name];
8
8
  return typeof value === 'string' ? value.trim() : '';
9
9
  }
10
- function readEnvironmentCredentials(env = process.env ?? {}) {
11
- const email = readEnvironmentValue(env, exports.ODA_EMAIL_ENV_VAR);
12
- const password = readEnvironmentValue(env, exports.ODA_PASSWORD_ENV_VAR);
10
+ function readEnvironmentCredentials(env = process.env) {
11
+ // Guard against null/undefined passed at runtime (e.g. from untyped JS callers).
12
+ const safeEnv = env ?? {};
13
+ const email = readEnvironmentValue(safeEnv, exports.ODA_EMAIL_ENV_VAR);
14
+ const password = readEnvironmentValue(safeEnv, exports.ODA_PASSWORD_ENV_VAR);
13
15
  if (!email || !password) {
14
16
  throw new Error('Oda credentials are required before using this plugin. ' +
15
17
  `Set both ${exports.ODA_EMAIL_ENV_VAR} and ${exports.ODA_PASSWORD_ENV_VAR} in the environment before launching OpenClaw.`);
@@ -1 +1 @@
1
- {"version":3,"file":"credentials.js","sourceRoot":"","sources":["../src/credentials.ts"],"names":[],"mappings":";;;AAKa,QAAA,iBAAiB,GAAG,WAAW,CAAC;AAChC,QAAA,oBAAoB,GAAG,cAAc,CAAC;AAEnD,SAAS,oBAAoB,CAAC,GAAsB,EAAE,IAAY;IAChE,MAAM,KAAK,GAAG,GAAG,EAAE,CAAC,IAAI,CAAC,CAAC;IAC1B,OAAO,OAAO,KAAK,KAAK,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;AACvD,CAAC;AAED,SAAgB,0BAA0B,CAAC,MAAyB,OAAO,CAAC,GAAG,IAAI,EAAE;IACnF,MAAM,KAAK,GAAG,oBAAoB,CAAC,GAAG,EAAE,yBAAiB,CAAC,CAAC;IAC3D,MAAM,QAAQ,GAAG,oBAAoB,CAAC,GAAG,EAAE,4BAAoB,CAAC,CAAC;IAEjE,IAAI,CAAC,KAAK,IAAI,CAAC,QAAQ,EAAE,CAAC;QACxB,MAAM,IAAI,KAAK,CACb,yDAAyD;YACvD,YAAY,yBAAiB,QAAQ,4BAAoB,gDAAgD,CAC5G,CAAC;IACJ,CAAC;IAED,OAAO,EAAE,KAAK,EAAE,QAAQ,EAAE,CAAC;AAC7B,CAAC;AAZD,gEAYC"}
1
+ {"version":3,"file":"credentials.js","sourceRoot":"","sources":["../src/credentials.ts"],"names":[],"mappings":";;;AAKa,QAAA,iBAAiB,GAAG,WAAW,CAAC;AAChC,QAAA,oBAAoB,GAAG,cAAc,CAAC;AAEnD,SAAS,oBAAoB,CAAC,GAAsB,EAAE,IAAY;IAChE,MAAM,KAAK,GAAG,GAAG,EAAE,CAAC,IAAI,CAAC,CAAC;IAC1B,OAAO,OAAO,KAAK,KAAK,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;AACvD,CAAC;AAED,SAAgB,0BAA0B,CAAC,MAAyB,OAAO,CAAC,GAAG;IAC7E,iFAAiF;IACjF,MAAM,OAAO,GAAsB,GAAG,IAAI,EAAE,CAAC;IAC7C,MAAM,KAAK,GAAG,oBAAoB,CAAC,OAAO,EAAE,yBAAiB,CAAC,CAAC;IAC/D,MAAM,QAAQ,GAAG,oBAAoB,CAAC,OAAO,EAAE,4BAAoB,CAAC,CAAC;IAErE,IAAI,CAAC,KAAK,IAAI,CAAC,QAAQ,EAAE,CAAC;QACxB,MAAM,IAAI,KAAK,CACb,yDAAyD;YACvD,YAAY,yBAAiB,QAAQ,4BAAoB,gDAAgD,CAC5G,CAAC;IACJ,CAAC;IAED,OAAO,EAAE,KAAK,EAAE,QAAQ,EAAE,CAAC;AAC7B,CAAC;AAdD,gEAcC"}
@@ -1,10 +1,11 @@
1
1
  {
2
2
  "id": "oda-groceries",
3
3
  "name": "Oda Groceries",
4
- "version": "0.1.8",
4
+ "version": "0.1.9",
5
5
  "description": "Browse groceries, review your shopping context, and apply confirmed cart changes.",
6
6
  "author": "oda-agent-kit",
7
7
  "license": "MIT",
8
+ "runtime": "node",
8
9
  "configSchema": {
9
10
  "type": "object",
10
11
  "description": "Set ODA_EMAIL and ODA_PASSWORD in the environment before launching OpenClaw. Reload the plugin after changing either value.",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@oda-agent/openclaw-plugin",
3
- "version": "0.5.0",
3
+ "version": "0.6.1",
4
4
  "description": "OpenClaw plugin for safe grocery planning and Oda automation",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -17,7 +17,7 @@
17
17
  "test": "jest"
18
18
  },
19
19
  "dependencies": {
20
- "@oda-agent/core": "^0.5.0"
20
+ "@oda-agent/core": "^0.6.1"
21
21
  },
22
22
  "devDependencies": {
23
23
  "@types/jest": "^29.5.0",