@peac/adapter-openclaw 0.10.12 → 0.10.13
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/index.cjs +6 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.mjs +8 -6
- package/dist/index.mjs.map +1 -1
- package/dist/keygen-cli.cjs.map +1 -1
- package/dist/keygen-cli.mjs.map +1 -1
- package/dist/plugin.d.ts.map +1 -1
- package/package.json +7 -7
package/dist/index.mjs
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
1
|
+
import * as crypto from '@peac/crypto';
|
|
2
|
+
import { canonicalize, generateKeypair, base64urlEncode as base64urlEncode$1 } from '@peac/crypto';
|
|
3
|
+
import * as captureCore from '@peac/capture-core';
|
|
4
|
+
import { toInteractionEvidence } from '@peac/capture-core';
|
|
3
5
|
import * as path from 'path';
|
|
4
6
|
import * as fs2 from 'fs/promises';
|
|
5
7
|
import { createFsSpoolStore, createFsDedupeIndex, getFsSpoolDiagnostics } from '@peac/capture-node';
|
|
@@ -486,10 +488,10 @@ function createJwkSigner(jwk, issuer, audience) {
|
|
|
486
488
|
if (!jwk.d) {
|
|
487
489
|
throw new Error("JWK must include private key (d parameter)");
|
|
488
490
|
}
|
|
489
|
-
const privateKeyBytes = base64urlDecode(jwk.d);
|
|
491
|
+
const privateKeyBytes = crypto.base64urlDecode(jwk.d);
|
|
490
492
|
return {
|
|
491
493
|
async sign(payload) {
|
|
492
|
-
return sign(payload, privateKeyBytes, kid);
|
|
494
|
+
return crypto.sign(payload, privateKeyBytes, kid);
|
|
493
495
|
},
|
|
494
496
|
getKeyId() {
|
|
495
497
|
return kid;
|
|
@@ -594,8 +596,8 @@ async function createPluginInstance(options) {
|
|
|
594
596
|
batchSize = 100,
|
|
595
597
|
onError
|
|
596
598
|
} = options;
|
|
597
|
-
const hasher = await createHasher();
|
|
598
|
-
const session = createCaptureSession({
|
|
599
|
+
const hasher = await captureCore.createHasher();
|
|
600
|
+
const session = captureCore.createCaptureSession({
|
|
599
601
|
store,
|
|
600
602
|
dedupe,
|
|
601
603
|
hasher
|