@blocklet/sdk 1.16.0 → 1.16.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.
@@ -12,6 +12,7 @@ const wallet_1 = require("@ocap/wallet");
12
12
  const constant_1 = __importDefault(require("@abtnode/constant"));
13
13
  const check_blocklet_env_1 = __importDefault(require("../util/check-blocklet-env"));
14
14
  const version_1 = require("../version");
15
+ const wallet_2 = __importDefault(require("../wallet"));
15
16
  const { NODE_SERVICES, WELLKNOWN_SERVICE_PATH_PREFIX, USER_AVATAR_URL_PREFIX, USER_AVATAR_PATH_PREFIX } = constant_1.default;
16
17
  const VERSION = version_1.version; // version of notification sdk
17
18
  const isNotNullOrUndefined = (x) => ![null, undefined].includes(x);
@@ -29,9 +30,10 @@ class AuthClient extends client_1.default {
29
30
  constructor(httpEndpoint) {
30
31
  (0, check_blocklet_env_1.default)();
31
32
  super(httpEndpoint || `http://127.0.0.1:${process.env.ABT_NODE_PORT}/api/gql`.trim(), `BlockletSDK/${VERSION}`);
33
+ const wallet = (0, wallet_2.default)();
32
34
  this.setAuthAccessKey({
33
- accessKeyId: process.env.BLOCKLET_APP_ID,
34
- accessKeySecret: process.env.BLOCKLET_APP_SK,
35
+ accessKeyId: wallet.address,
36
+ accessKeySecret: wallet.secretKey,
35
37
  type,
36
38
  });
37
39
  }
package/lib/version.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- declare const version = "1.16.0";
1
+ declare const version = "1.16.1";
2
2
  export { version };
3
3
  declare const _default: {
4
4
  version: string;
package/lib/version.js CHANGED
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.version = void 0;
4
- const version = '1.16.0';
4
+ const version = '1.16.1';
5
5
  exports.version = version;
6
6
  exports.default = { version };
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "publishConfig": {
4
4
  "access": "public"
5
5
  },
6
- "version": "1.16.0",
6
+ "version": "1.16.1",
7
7
  "description": "graphql client to read/write data on abt node",
8
8
  "main": "lib/index.js",
9
9
  "typings": "lib/index.d.ts",
@@ -26,15 +26,15 @@
26
26
  "author": "linchen1987 <linchen.1987@foxmail.com> (http://github.com/linchen1987)",
27
27
  "license": "MIT",
28
28
  "dependencies": {
29
- "@abtnode/client": "1.16.0",
30
- "@abtnode/constant": "1.16.0",
29
+ "@abtnode/client": "1.16.1",
30
+ "@abtnode/constant": "1.16.1",
31
31
  "@arcblock/did": "1.18.65",
32
32
  "@arcblock/did-auth": "1.18.65",
33
33
  "@arcblock/jwt": "1.18.65",
34
34
  "@arcblock/ws": "1.18.65",
35
- "@blocklet/constant": "1.16.0",
36
- "@blocklet/env": "1.16.0",
37
- "@blocklet/meta": "1.16.0",
35
+ "@blocklet/constant": "1.16.1",
36
+ "@blocklet/env": "1.16.1",
37
+ "@blocklet/meta": "1.16.1",
38
38
  "@did-connect/authenticator": "^2.1.47",
39
39
  "@did-connect/handler": "^2.1.47",
40
40
  "@nedb/core": "^2.1.5",
@@ -72,5 +72,5 @@
72
72
  "ts-node": "^10.9.1",
73
73
  "typescript": "^4.8.4"
74
74
  },
75
- "gitHead": "da461546c6db9c7d347689708af27654c17ac28e"
75
+ "gitHead": "5912cfbd3b7573850727b05a808b1f798686267f"
76
76
  }