@openclaw/nostr 2026.5.14-beta.1 → 2026.5.16-beta.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.
- package/dist/api.js +2 -2
- package/dist/{channel-CUWdJVns.js → channel-DhEeY6pk.js} +1 -1
- package/dist/channel-plugin-api.js +1 -1
- package/dist/setup-api.js +1 -1
- package/dist/setup-plugin-api.js +7 -6
- package/dist/{setup-surface-B5s49fq2.js → setup-surface-BEpiebD3.js} +24 -23
- package/dist/test-api.js +1 -1
- package/package.json +4 -4
package/dist/api.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { o as resolveNostrAccount } from "./setup-surface-
|
|
1
|
+
import { o as resolveNostrAccount } from "./setup-surface-BEpiebD3.js";
|
|
2
2
|
import { getPluginRuntimeGatewayRequestScope } from "./runtime-api.js";
|
|
3
3
|
import { n as NostrProfileSchema } from "./config-schema-TI8Kr8Vn.js";
|
|
4
|
-
import { a as setNostrRuntime, i as getNostrRuntime, n as nostrPlugin, o as contentToProfile, r as publishNostrProfile, t as getNostrProfileState } from "./channel-
|
|
4
|
+
import { a as setNostrRuntime, i as getNostrRuntime, n as nostrPlugin, o as contentToProfile, r as publishNostrProfile, t as getNostrProfileState } from "./channel-DhEeY6pk.js";
|
|
5
5
|
import { z } from "zod";
|
|
6
6
|
import { SimplePool, verifyEvent } from "nostr-tools";
|
|
7
7
|
import { normalizeLowercaseStringOrEmpty, normalizeOptionalLowercaseString, readStringValue } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as resolveDefaultNostrAccountId, c as validatePrivateKey, i as listNostrAccountIds, n as nostrSetupWizard, o as resolveNostrAccount, s as normalizePubkey, t as nostrSetupAdapter } from "./setup-surface-
|
|
1
|
+
import { a as resolveDefaultNostrAccountId, c as validatePrivateKey, i as listNostrAccountIds, n as nostrSetupWizard, o as resolveNostrAccount, s as normalizePubkey, t as nostrSetupAdapter } from "./setup-surface-BEpiebD3.js";
|
|
2
2
|
import { a as collectStatusIssuesFromLastError, i as buildChannelConfigSchema, n as NostrProfileSchema, o as createDefaultChannelRuntimeState, r as DEFAULT_ACCOUNT_ID, s as formatPairingApproveHint, t as NostrConfigSchema } from "./config-schema-TI8Kr8Vn.js";
|
|
3
3
|
import { t as DEFAULT_RELAYS } from "./default-relays-DLwdWOTu.js";
|
|
4
4
|
import { describeAccountSnapshot } from "openclaw/plugin-sdk/account-helpers";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as nostrPlugin } from "./channel-
|
|
1
|
+
import { n as nostrPlugin } from "./channel-DhEeY6pk.js";
|
|
2
2
|
export { nostrPlugin };
|
package/dist/setup-api.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as nostrSetupWizard, t as nostrSetupAdapter } from "./setup-surface-
|
|
1
|
+
import { n as nostrSetupWizard, t as nostrSetupAdapter } from "./setup-surface-BEpiebD3.js";
|
|
2
2
|
export { nostrSetupAdapter, nostrSetupWizard };
|
package/dist/setup-plugin-api.js
CHANGED
|
@@ -2,8 +2,9 @@ import { i as buildChannelConfigSchema, t as NostrConfigSchema } from "./config-
|
|
|
2
2
|
import { t as DEFAULT_RELAYS } from "./default-relays-DLwdWOTu.js";
|
|
3
3
|
import { describeAccountSnapshot } from "openclaw/plugin-sdk/account-helpers";
|
|
4
4
|
import { patchTopLevelChannelConfigSection } from "openclaw/plugin-sdk/setup";
|
|
5
|
-
import { DEFAULT_ACCOUNT_ID, createDelegatedSetupWizardProxy, createStandardChannelSetupStatus as createStandardChannelSetupStatus$1 } from "openclaw/plugin-sdk/setup-runtime";
|
|
5
|
+
import { DEFAULT_ACCOUNT_ID, createDelegatedSetupWizardProxy, createSetupTranslator as createSetupTranslator$1, createStandardChannelSetupStatus as createStandardChannelSetupStatus$1 } from "openclaw/plugin-sdk/setup-runtime";
|
|
6
6
|
//#region extensions/nostr/src/channel.setup.ts
|
|
7
|
+
const t = createSetupTranslator$1();
|
|
7
8
|
const channel = "nostr";
|
|
8
9
|
function getNostrConfig(cfg) {
|
|
9
10
|
return cfg.channels?.nostr;
|
|
@@ -105,13 +106,13 @@ const nostrSetupAdapter = {
|
|
|
105
106
|
};
|
|
106
107
|
const nostrSetupWizard = createDelegatedSetupWizardProxy({
|
|
107
108
|
channel,
|
|
108
|
-
loadWizard: async () => (await import("./setup-surface-
|
|
109
|
+
loadWizard: async () => (await import("./setup-surface-BEpiebD3.js").then((n) => n.r)).nostrSetupWizard,
|
|
109
110
|
status: { ...createStandardChannelSetupStatus$1({
|
|
110
111
|
channelLabel: "Nostr",
|
|
111
|
-
configuredLabel: "
|
|
112
|
-
unconfiguredLabel: "
|
|
113
|
-
configuredHint: "
|
|
114
|
-
unconfiguredHint: "
|
|
112
|
+
configuredLabel: t("wizard.channels.statusConfigured"),
|
|
113
|
+
unconfiguredLabel: t("wizard.channels.statusNeedsPrivateKey"),
|
|
114
|
+
configuredHint: t("wizard.channels.statusConfigured"),
|
|
115
|
+
unconfiguredHint: t("wizard.channels.statusNeedsPrivateKey"),
|
|
115
116
|
configuredScore: 1,
|
|
116
117
|
unconfiguredScore: 0,
|
|
117
118
|
includeStatusLine: true,
|
|
@@ -5,7 +5,7 @@ import { DEFAULT_ACCOUNT_ID, normalizeAccountId, normalizeOptionalAccountId } fr
|
|
|
5
5
|
import { listCombinedAccountIds, resolveListedDefaultAccountId } from "openclaw/plugin-sdk/account-resolution";
|
|
6
6
|
import { normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
7
7
|
import { DEFAULT_ACCOUNT_ID as DEFAULT_ACCOUNT_ID$1 } from "openclaw/plugin-sdk/routing";
|
|
8
|
-
import { createStandardChannelSetupStatus, createTopLevelChannelDmPolicy, createTopLevelChannelParsedAllowFromPrompt, formatDocsLink, mergeAllowFromEntries, parseSetupEntriesWithParser, patchTopLevelChannelConfigSection, splitSetupEntries } from "openclaw/plugin-sdk/setup";
|
|
8
|
+
import { createSetupTranslator, createStandardChannelSetupStatus, createTopLevelChannelDmPolicy, createTopLevelChannelParsedAllowFromPrompt, formatDocsLink, mergeAllowFromEntries, parseSetupEntriesWithParser, patchTopLevelChannelConfigSection, splitSetupEntries } from "openclaw/plugin-sdk/setup";
|
|
9
9
|
//#region \0rolldown/runtime.js
|
|
10
10
|
var __defProp = Object.defineProperty;
|
|
11
11
|
var __exportAll = (all, no_symbols) => {
|
|
@@ -117,20 +117,21 @@ var setup_surface_exports = /* @__PURE__ */ __exportAll({
|
|
|
117
117
|
nostrSetupAdapter: () => nostrSetupAdapter,
|
|
118
118
|
nostrSetupWizard: () => nostrSetupWizard
|
|
119
119
|
});
|
|
120
|
+
const t = createSetupTranslator();
|
|
120
121
|
const channel = "nostr";
|
|
121
122
|
const NOSTR_SETUP_HELP_LINES = [
|
|
122
|
-
"
|
|
123
|
-
"
|
|
124
|
-
"
|
|
123
|
+
t("wizard.nostr.helpPrivateKeyFormat"),
|
|
124
|
+
t("wizard.nostr.helpRelaysOptional"),
|
|
125
|
+
t("wizard.nostr.helpEnvVars"),
|
|
125
126
|
`Docs: ${formatDocsLink("/channels/nostr", "channels/nostr")}`
|
|
126
127
|
];
|
|
127
128
|
const NOSTR_ALLOW_FROM_HELP_LINES = [
|
|
128
|
-
"
|
|
129
|
-
"
|
|
129
|
+
t("wizard.nostr.allowlistIntro"),
|
|
130
|
+
t("wizard.nostr.examples"),
|
|
130
131
|
"- npub1...",
|
|
131
132
|
"- nostr:npub1...",
|
|
132
133
|
"- 0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef",
|
|
133
|
-
"
|
|
134
|
+
t("wizard.nostr.multipleEntries"),
|
|
134
135
|
`Docs: ${formatDocsLink("/channels/nostr", "channels/nostr")}`
|
|
135
136
|
];
|
|
136
137
|
function buildNostrSetupPatch(accountId, patch) {
|
|
@@ -178,9 +179,9 @@ const nostrDmPolicy = createTopLevelChannelDmPolicy({
|
|
|
178
179
|
promptAllowFrom: createTopLevelChannelParsedAllowFromPrompt({
|
|
179
180
|
channel,
|
|
180
181
|
defaultAccountId: resolveDefaultNostrAccountId,
|
|
181
|
-
noteTitle: "
|
|
182
|
+
noteTitle: t("wizard.nostr.allowlistTitle"),
|
|
182
183
|
noteLines: NOSTR_ALLOW_FROM_HELP_LINES,
|
|
183
|
-
message: "
|
|
184
|
+
message: t("wizard.nostr.allowFromPrompt"),
|
|
184
185
|
placeholder: "npub1..., 0123abcd...",
|
|
185
186
|
parseEntries: parseNostrAllowFrom,
|
|
186
187
|
mergeEntries: ({ existing, parsed }) => mergeAllowFromEntries(existing, parsed)
|
|
@@ -228,10 +229,10 @@ const nostrSetupWizard = {
|
|
|
228
229
|
resolveShouldPromptAccountIds: () => false,
|
|
229
230
|
status: createStandardChannelSetupStatus({
|
|
230
231
|
channelLabel: "Nostr",
|
|
231
|
-
configuredLabel: "
|
|
232
|
-
unconfiguredLabel: "
|
|
233
|
-
configuredHint: "
|
|
234
|
-
unconfiguredHint: "
|
|
232
|
+
configuredLabel: t("wizard.channels.statusConfigured"),
|
|
233
|
+
unconfiguredLabel: t("wizard.channels.statusNeedsPrivateKey"),
|
|
234
|
+
configuredHint: t("wizard.channels.statusConfigured"),
|
|
235
|
+
unconfiguredHint: t("wizard.channels.statusNeedsPrivateKey"),
|
|
235
236
|
configuredScore: 1,
|
|
236
237
|
unconfiguredScore: 0,
|
|
237
238
|
includeStatusLine: true,
|
|
@@ -241,11 +242,11 @@ const nostrSetupWizard = {
|
|
|
241
242
|
}
|
|
242
243
|
}),
|
|
243
244
|
introNote: {
|
|
244
|
-
title: "
|
|
245
|
+
title: t("wizard.nostr.setupTitle"),
|
|
245
246
|
lines: NOSTR_SETUP_HELP_LINES
|
|
246
247
|
},
|
|
247
248
|
envShortcut: {
|
|
248
|
-
prompt: "
|
|
249
|
+
prompt: t("wizard.nostr.privateKeyEnvPrompt"),
|
|
249
250
|
preferredEnvVar: "NOSTR_PRIVATE_KEY",
|
|
250
251
|
isAvailable: ({ cfg, accountId }) => accountId === DEFAULT_ACCOUNT_ID$1 && Boolean(process.env.NOSTR_PRIVATE_KEY?.trim()) && !hasConfiguredSecretInput(resolveNostrAccount({
|
|
251
252
|
cfg,
|
|
@@ -264,11 +265,11 @@ const nostrSetupWizard = {
|
|
|
264
265
|
providerHint: channel,
|
|
265
266
|
credentialLabel: "private key",
|
|
266
267
|
preferredEnvVar: "NOSTR_PRIVATE_KEY",
|
|
267
|
-
helpTitle: "
|
|
268
|
+
helpTitle: t("wizard.nostr.privateKeyTitle"),
|
|
268
269
|
helpLines: NOSTR_SETUP_HELP_LINES,
|
|
269
|
-
envPrompt: "
|
|
270
|
-
keepPrompt: "
|
|
271
|
-
inputPrompt: "
|
|
270
|
+
envPrompt: t("wizard.nostr.privateKeyEnvPrompt"),
|
|
271
|
+
keepPrompt: t("wizard.nostr.privateKeyKeep"),
|
|
272
|
+
inputPrompt: t("wizard.nostr.privateKeyInput"),
|
|
272
273
|
allowEnv: ({ accountId }) => accountId === DEFAULT_ACCOUNT_ID$1,
|
|
273
274
|
inspect: ({ cfg, accountId }) => {
|
|
274
275
|
const account = resolveNostrAccount({
|
|
@@ -298,12 +299,12 @@ const nostrSetupWizard = {
|
|
|
298
299
|
}],
|
|
299
300
|
textInputs: [{
|
|
300
301
|
inputKey: "relayUrls",
|
|
301
|
-
message: "
|
|
302
|
+
message: t("wizard.nostr.relayUrlsPrompt"),
|
|
302
303
|
placeholder: DEFAULT_RELAYS.join(", "),
|
|
303
304
|
required: false,
|
|
304
305
|
applyEmptyValue: true,
|
|
305
|
-
helpTitle: "
|
|
306
|
-
helpLines: ["
|
|
306
|
+
helpTitle: t("wizard.nostr.relaysTitle"),
|
|
307
|
+
helpLines: [t("wizard.nostr.relaysWsOnly"), t("wizard.nostr.helpRelaysOptional")],
|
|
307
308
|
currentValue: ({ cfg, accountId }) => {
|
|
308
309
|
const account = resolveNostrAccount({
|
|
309
310
|
cfg,
|
|
@@ -312,7 +313,7 @@ const nostrSetupWizard = {
|
|
|
312
313
|
const configuredRelays = cfg.channels?.nostr?.relays;
|
|
313
314
|
return (configuredRelays && configuredRelays.length > 0 ? account.relays : []).join(", ");
|
|
314
315
|
},
|
|
315
|
-
keepPrompt: (value) =>
|
|
316
|
+
keepPrompt: (value) => t("wizard.nostr.relayUrlsKeep", { value }),
|
|
316
317
|
validate: ({ value }) => parseRelayUrls(value).error,
|
|
317
318
|
applySet: async ({ cfg, accountId, value }) => {
|
|
318
319
|
const relayResult = parseRelayUrls(value);
|
package/dist/test-api.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as nostrPlugin } from "./channel-
|
|
1
|
+
import { n as nostrPlugin } from "./channel-DhEeY6pk.js";
|
|
2
2
|
export { nostrPlugin };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openclaw/nostr",
|
|
3
|
-
"version": "2026.5.
|
|
3
|
+
"version": "2026.5.16-beta.1",
|
|
4
4
|
"description": "OpenClaw Nostr channel plugin for NIP-04 encrypted DMs",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
"openclaw": "workspace:*"
|
|
17
17
|
},
|
|
18
18
|
"peerDependencies": {
|
|
19
|
-
"openclaw": ">=2026.5.
|
|
19
|
+
"openclaw": ">=2026.5.16-beta.1"
|
|
20
20
|
},
|
|
21
21
|
"peerDependenciesMeta": {
|
|
22
22
|
"openclaw": {
|
|
@@ -54,10 +54,10 @@
|
|
|
54
54
|
"minHostVersion": ">=2026.4.10"
|
|
55
55
|
},
|
|
56
56
|
"compat": {
|
|
57
|
-
"pluginApi": ">=2026.5.
|
|
57
|
+
"pluginApi": ">=2026.5.16-beta.1"
|
|
58
58
|
},
|
|
59
59
|
"build": {
|
|
60
|
-
"openclawVersion": "2026.5.
|
|
60
|
+
"openclawVersion": "2026.5.16-beta.1"
|
|
61
61
|
},
|
|
62
62
|
"release": {
|
|
63
63
|
"publishToClawHub": true,
|