@ardrive/turbo-sdk 1.5.0-alpha.2 → 1.5.0-alpha.3

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/README.md CHANGED
@@ -47,7 +47,7 @@ yarn add @ardrive/turbo-sdk
47
47
  ## Quick Start
48
48
 
49
49
  ```typescript
50
- import { TurboFactory } from '@ardrive/turbo-sdk';
50
+ import { TurboFactory, ArweaveSigner } from '@ardrive/turbo-sdk';
51
51
 
52
52
  // load your JWK directly to authenticate
53
53
  const jwk = fs.readFileSync('./my-jwk.json');
@@ -130843,7 +130843,7 @@ var import_winston = __toESM(require_winston(), 1);
130843
130843
  init_dirname();
130844
130844
  init_buffer2();
130845
130845
  init_process2();
130846
- var version21 = "1.5.0-alpha.1";
130846
+ var version21 = "1.5.0-alpha.2";
130847
130847
 
130848
130848
  // src/common/logger.ts
130849
130849
  var TurboWinstonLogger = class {
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.TurboDataItemAbstractSigner = void 0;
3
+ exports.TurboDataItemAbstractSigner = exports.ArweaveSigner = exports.ArconnectSigner = void 0;
4
4
  /**
5
5
  * Copyright (C) 2022-2023 Permanent Data Solutions, Inc. All Rights Reserved.
6
6
  *
@@ -17,8 +17,14 @@ exports.TurboDataItemAbstractSigner = void 0;
17
17
  * You should have received a copy of the GNU Affero General Public License
18
18
  * along with this program. If not, see <http://www.gnu.org/licenses/>.
19
19
  */
20
+ const arbundles_1 = require("arbundles");
21
+ Object.defineProperty(exports, "ArconnectSigner", { enumerable: true, get: function () { return arbundles_1.ArconnectSigner; } });
22
+ Object.defineProperty(exports, "ArweaveSigner", { enumerable: true, get: function () { return arbundles_1.ArweaveSigner; } });
20
23
  const crypto_1 = require("crypto");
21
24
  const base64_js_1 = require("../utils/base64.js");
25
+ /**
26
+ * Abstract class for signing TurboDataItems.
27
+ */
22
28
  class TurboDataItemAbstractSigner {
23
29
  constructor({ signer, logger }) {
24
30
  this.logger = logger;
@@ -18,4 +18,4 @@
18
18
  Object.defineProperty(exports, "__esModule", { value: true });
19
19
  exports.version = void 0;
20
20
  // AUTOMATICALLY GENERATED FILE - DO NOT TOUCH
21
- exports.version = '1.5.0-alpha.2';
21
+ exports.version = '1.5.0-alpha.3';
@@ -14,8 +14,16 @@
14
14
  * You should have received a copy of the GNU Affero General Public License
15
15
  * along with this program. If not, see <http://www.gnu.org/licenses/>.
16
16
  */
17
+ import { ArconnectSigner, ArweaveSigner } from 'arbundles';
17
18
  import { randomBytes } from 'crypto';
18
19
  import { toB64Url } from '../utils/base64.js';
20
+ /**
21
+ * Utility exports to avoid clients having to install arbundles
22
+ */
23
+ export { ArconnectSigner, ArweaveSigner };
24
+ /**
25
+ * Abstract class for signing TurboDataItems.
26
+ */
19
27
  export class TurboDataItemAbstractSigner {
20
28
  constructor({ signer, logger }) {
21
29
  this.logger = logger;
@@ -15,4 +15,4 @@
15
15
  * along with this program. If not, see <http://www.gnu.org/licenses/>.
16
16
  */
17
17
  // AUTOMATICALLY GENERATED FILE - DO NOT TOUCH
18
- export const version = '1.5.0-alpha.2';
18
+ export const version = '1.5.0-alpha.3';
@@ -1,5 +1,29 @@
1
1
  /// <reference types="node" />
2
+ /**
3
+ * Copyright (C) 2022-2023 Permanent Data Solutions, Inc. All Rights Reserved.
4
+ *
5
+ * This program is free software: you can redistribute it and/or modify
6
+ * it under the terms of the GNU Affero General Public License as published by
7
+ * the Free Software Foundation, either version 3 of the License, or
8
+ * (at your option) any later version.
9
+ *
10
+ * This program is distributed in the hope that it will be useful,
11
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
+ * GNU Affero General Public License for more details.
14
+ *
15
+ * You should have received a copy of the GNU Affero General Public License
16
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
17
+ */
18
+ import { ArconnectSigner, ArweaveSigner } from 'arbundles';
2
19
  import { FileStreamFactory, TurboDataItemSigner, TurboDataItemSignerParams, TurboFileFactory, TurboLogger, TurboSignedDataItemFactory, TurboSigner } from '../types.js';
20
+ /**
21
+ * Utility exports to avoid clients having to install arbundles
22
+ */
23
+ export { ArconnectSigner, ArweaveSigner };
24
+ /**
25
+ * Abstract class for signing TurboDataItems.
26
+ */
3
27
  export declare abstract class TurboDataItemAbstractSigner implements TurboDataItemSigner {
4
28
  abstract signDataItem({ fileStreamFactory, fileSizeFactory, dataItemOpts, }: TurboFileFactory<FileStreamFactory>): Promise<TurboSignedDataItemFactory>;
5
29
  protected logger: TurboLogger;
@@ -1 +1 @@
1
- {"version":3,"file":"signer.d.ts","sourceRoot":"","sources":["../../../src/common/signer.ts"],"names":[],"mappings":";AAkBA,OAAO,EACL,iBAAiB,EACjB,mBAAmB,EACnB,yBAAyB,EACzB,gBAAgB,EAChB,WAAW,EACX,0BAA0B,EAC1B,WAAW,EACZ,MAAM,aAAa,CAAC;AAGrB,8BAAsB,2BACpB,YAAW,mBAAmB;IAE9B,QAAQ,CAAC,YAAY,CAAC,EACpB,iBAAiB,EACjB,eAAe,EACf,YAAY,GACb,EAAE,gBAAgB,CAAC,iBAAiB,CAAC,GAAG,OAAO,CAAC,0BAA0B,CAAC;IAE5E,SAAS,CAAC,MAAM,EAAE,WAAW,CAAC;IAC9B,SAAS,CAAC,MAAM,EAAE,WAAW,CAAC;gBAElB,EAAE,MAAM,EAAE,MAAM,EAAE,EAAE,yBAAyB;IAK5C,4BAA4B;;;;;IAY5B,YAAY,IAAI,OAAO,CAAC,MAAM,CAAC;IAI/B,QAAQ,CAAC,UAAU,EAAE,UAAU,GAAG,OAAO,CAAC,UAAU,CAAC;CAGnE"}
1
+ {"version":3,"file":"signer.d.ts","sourceRoot":"","sources":["../../../src/common/signer.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;GAeG;AACH,OAAO,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,WAAW,CAAC;AAG3D,OAAO,EACL,iBAAiB,EACjB,mBAAmB,EACnB,yBAAyB,EACzB,gBAAgB,EAChB,WAAW,EACX,0BAA0B,EAC1B,WAAW,EACZ,MAAM,aAAa,CAAC;AAGrB;;GAEG;AACH,OAAO,EAAE,eAAe,EAAE,aAAa,EAAE,CAAC;AAE1C;;GAEG;AACH,8BAAsB,2BACpB,YAAW,mBAAmB;IAE9B,QAAQ,CAAC,YAAY,CAAC,EACpB,iBAAiB,EACjB,eAAe,EACf,YAAY,GACb,EAAE,gBAAgB,CAAC,iBAAiB,CAAC,GAAG,OAAO,CAAC,0BAA0B,CAAC;IAE5E,SAAS,CAAC,MAAM,EAAE,WAAW,CAAC;IAC9B,SAAS,CAAC,MAAM,EAAE,WAAW,CAAC;gBAElB,EAAE,MAAM,EAAE,MAAM,EAAE,EAAE,yBAAyB;IAK5C,4BAA4B;;;;;IAY5B,YAAY,IAAI,OAAO,CAAC,MAAM,CAAC;IAI/B,QAAQ,CAAC,UAAU,EAAE,UAAU,GAAG,OAAO,CAAC,UAAU,CAAC;CAGnE"}
@@ -14,5 +14,5 @@
14
14
  * You should have received a copy of the GNU Affero General Public License
15
15
  * along with this program. If not, see <http://www.gnu.org/licenses/>.
16
16
  */
17
- export declare const version = "1.5.0-alpha.1";
17
+ export declare const version = "1.5.0-alpha.2";
18
18
  //# sourceMappingURL=version.d.ts.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ardrive/turbo-sdk",
3
- "version": "1.5.0-alpha.2",
3
+ "version": "1.5.0-alpha.3",
4
4
  "main": "./lib/cjs/node/index.js",
5
5
  "types": "./lib/types/node/index.d.ts",
6
6
  "module": "./lib/esm/node/index.js",