@@ -82,14 +59,7 @@
-
+
@@ -101,32 +71,15 @@
- Copy address
+ Copy address
Your endpoint:
-
+
-
+
@@ -134,13 +87,8 @@
Sender Private Key:
-
+
@@ -149,8 +97,7 @@
No not use your real private key! Leave empty for a randomly
- generated key.
+ generated key.
@@ -159,13 +106,7 @@
Sender Public Key:
-
+
@@ -173,15 +114,8 @@
Test Message:
-
+
@@ -189,35 +123,22 @@
Receiver Public Key:
-
+
- This is the recipient of the message. Field required.
+ This is the recipient of the message. Field required.
- Send Message
+ Send Message
@@ -229,14 +150,7 @@
Sent Data:
-
+
@@ -244,14 +158,7 @@
Received Data:
-
+
@@ -270,12 +177,8 @@
-
+
Only Admin users can manage this extension.
@@ -356,7 +259,15 @@
pagination: {
rowsPerPage: 10
}
- }
+ },
+ predefinedRelays: [
+ "wss://relay.damus.io",
+ "wss://nostr-pub.wellorder.net",
+ "wss://nostr.zebedee.cloud",
+ "wss://nodestr.fmt.wiz.biz",
+ "wss://nostr.oxtr.dev",
+ "wss://nostr.wine"
+ ],
}
},
methods: {
@@ -399,7 +310,7 @@
'POST',
'/nostrclient/api/v1/relay?usr=' + this.g.user.id,
this.g.user.wallets[0].adminkey,
- {url: this.relayToAdd}
+ { url: this.relayToAdd }
)
.then(function (response) {
console.log('response:', response)
@@ -414,6 +325,10 @@
})
return false
},
+ async addCustomRelay(relayUrl) {
+ this.relayToAdd = relayUrl
+ await this.addRelay()
+ },
deleteRelay(url) {
console.log('DELETE RELAY ' + url)
LNbits.api
@@ -421,7 +336,7 @@
'DELETE',
'/nostrclient/api/v1/relay?usr=' + this.g.user.id,
this.g.user.wallets[0].adminkey,
- {url: url}
+ { url: url }
)
.then(function (response) {
if (response.data) {
@@ -469,7 +384,7 @@
},
sendTestMessage: async function () {
try {
- const {data} = await LNbits.api.request(
+ const { data } = await LNbits.api.request(
'PUT',
'/nostrclient/api/v1/relay/test?usr=' + this.g.user.id,
this.g.user.wallets[0].adminkey,
@@ -490,7 +405,7 @@
const subscription = JSON.stringify([
'REQ',
'test-dms',
- {kinds: [4], '#p': [event.pubkey]}
+ { kinds: [4], '#p': [event.pubkey] }
])
this.testData.wsConnection.send(subscription)
} catch (error) {
@@ -555,4 +470,4 @@
}
})
-{% endblock %}
+{% endblock %}
\ No newline at end of file