git ssb

3+

cel / ssb-publishguard



Commit 043153f4feb56ac8a710e91fd243efb4a3ae8d03

Add muxrpc-usage help

cel committed on 8/28/2019, 10:52:14 PM
Parent: 5a3cd636ffd4211ee7958de59fc2011a7d6f58eb

Files changed

index.jschanged
index.jsView
@@ -1,12 +1,56 @@
11 var ssbKeys = require('ssb-keys')
22 var confirmer = require('./confirm')
33
4 +var help = {
5 + description: 'Publish messages via user-confirmation',
6 + commands: {
7 + publishGetUrl: {
8 + description: 'Create a URL with a confirmation form for publishing a message',
9 + type: 'async',
10 + args: {
11 + content: {
12 + type: 'object',
13 + optional: false,
14 + description: 'message content to publish'
15 + },
16 + redirectBase: {
17 + type: 'URL',
18 + optional: false,
19 + description: 'Base URL for post-publish redirect - with the message ID, URL-encoded, appended'
20 + }
21 + }
22 + },
23 + privatePublishGetUrl: {
24 + description: 'Create a URL with a confirmation form for publishing a private message',
25 + type: 'async',
26 + args: {
27 + content: {
28 + type: 'object',
29 + optional: false,
30 + description: 'message content to publish privately'
31 + },
32 + redirectBase: {
33 + type: 'URL',
34 + optional: false,
35 + description: 'base URL for post-publish redirect - with the message ID, URL-encoded, appended'
36 + },
37 + recps: {
38 + type: 'FeedIds',
39 + optional: false,
40 + description: 'feed ids to encrypt message to with private-box'
41 + }
42 + }
43 + }
44 + }
45 +}
46 +
447 exports.name = 'publishguard'
548 exports.version = '1.1.0'
649 exports.manifest = {
750 publishGetUrl: 'async',
851 privatePublishGetUrl: 'async',
52 + help: 'sync',
953 }
1054 exports.init = function (sbot, config) {
1155 var confirm
1256 setTimeout(function () {
@@ -43,7 +87,10 @@
4387 privatePublishGetUrl: function (opts, cb) {
4488 if (!opts) throw new TypeError('missing opts')
4589 if (typeof cb !== 'function') throw new TypeError('bad callback')
4690 confirm.privatePublishGetUrl(opts, cb)
91 + },
92 + help: function () {
93 + return help
4794 }
4895 }
4996 }

Built with git-ssb-web