mirror of
https://github.com/ElementsProject/lightning.git
synced 2024-11-19 18:11:28 +01:00
17 lines
327 B
Python
Executable File
17 lines
327 B
Python
Executable File
#!/usr/bin/env python3
|
|
from pyln.client import Plugin
|
|
|
|
plugin = Plugin()
|
|
|
|
|
|
@plugin.hook('custommsg')
|
|
def on_custommsg(peer_id, message, plugin, **kwargs):
|
|
plugin.log("Got custommessage_b {msg} from peer {peer_id}".format(
|
|
msg=message,
|
|
peer_id=peer_id
|
|
))
|
|
return {'result': 'continue'}
|
|
|
|
|
|
plugin.run()
|