signal-cli icon indicating copy to clipboard operation
signal-cli copied to clipboard

Feature request: Persist incoming messages to disc

Open MrFly opened this issue 2 years ago • 1 comments

When running signal-cli as daemon (dbus-system) with systemd it is nearly impossible to grab ALL of the messages programmatically.

Messages at sysout were grabbed from systemd. Running e.g. a Java program which calls "receive" (with --dbus-system) will not get all messages. It's really complicated to get them safe. The only way I found was to dig in the syslog about new messages - but this is not a good way.

I suggest a parameter for signal-cli, like e.g. "--message-folder" or "--persist-messages" where every message will be persisted, human readable (like sysout) or json. The message file should contain the timestamp, so it will be possible to work them fifo. Cool would also be to filter by "real" message. Currently all of the messages (like sync requests a.s.o) are in one "pool". Separating them at server side would be really helpful.

MrFly avatar Jan 23 '23 07:01 MrFly

Looks like https://github.com/AsamK/signal-cli/issues/895 might be related. Subscribing to dbus, filter what you want and dump to folder.

Python example in https://github.com/AsamK/signal-cli/wiki/DBus-service#receive-messages-from-signal-cli-daemon

morph027 avatar Feb 28 '24 09:02 morph027