gudnuf / bolt12-prism

CLN plugin for lightning prisms using BOLT 12
16 stars 5 forks source link

Recommendation: RPC syntax should be changed to "prism-<method>" #60

Closed farscapian closed 9 months ago

farscapian commented 1 year ago

It is much easier to write Rune's when the RPC methods are consistent. I recommend changing all RPC method names to the prism-<action> format. This allows you to write runes like this: restrictions='[["method^prism-","rate=120"]]'

  1. createprism (creates a single prism, returns a single prism_id) --> prism-create
  2. listprisms (lists all prisms) --> prism-list
  3. listprism (shows a single prism) -- prism-show <prism_id>
  4. deleteprism --> prism-delete <prism_id>
  5. updateprism --> prism-update <prism_id> members[]

Suggested NEW RPC Methods:

  1. prism-execute <prism_id> <amount_msats> <label> (invokes prism payment logic OUTSIDE of the regular payment flow).