https://github.com/interledgerjs/ilp-plugin-outgoing-settle
Outgoing-only plugin that sends XRP settlements.
https://github.com/interledgerjs/ilp-plugin-outgoing-settle
Last synced: 7 days ago
JSON representation
Outgoing-only plugin that sends XRP settlements.
- Host: GitHub
- URL: https://github.com/interledgerjs/ilp-plugin-outgoing-settle
- Owner: interledgerjs
- Created: 2018-01-12T21:59:22.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2018-04-03T23:16:33.000Z (about 8 years ago)
- Last Synced: 2025-02-25T14:56:18.340Z (over 1 year ago)
- Language: JavaScript
- Size: 109 KB
- Stars: 0
- Watchers: 3
- Forks: 1
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# ILP Plugin Outgoing Settle
> Outgoing-only plugin that sends XRP settlements. Edit
- [Description](#description)
- [Example](#example)
## Description
This plugin allows users to connect dynamically (similar to mini-accounts), and
then fulfill incoming payments. They cannot send outgoing payments from this
plugin, so all balance logic is one-way. The plugin buffers their incoming ILP
payments and periodically settles them on-chain via XRP.
Although it is not included in this plugin, this 'accumulate and settle' model
can be written for other systems. For systems more expensive than XRP, the fee
should be taken into account when sending settlements.
Once the receiver has accumulated `settleThreshold` drops, (by default 1000
drops if the account exists, or 25 XRP if it doesn't), this plugin will trigger
an XRP payment to that address.
## Example
```js
const plugin = new IlpPluginOutgoingSettle({
port: 8080,
secret: 's...',
address: 'r...',
xrpServer: 'wss://s1.ripple.com',
settleThreshold: 1000, // default 1000 drops for accounts that exist, 25 XRP for new accounts
_store: new Store() // passed in by connector automatically
})
```
Clients connecting to this plugin should connect with a server url of:
```
"btp+ws://:@localhost:8080/"
```
The `` in the URL determines where settlements are sent. Once
you have authenticated with a `` and a ``, you cannot
supply any other `` when connecting to that account. This is to
prevent funds from being diverted if anyone should find out your ``.