For instructions on running the ILP Node, see the Readme.
The ILP Node uses HTTP Bearer tokens for authorization.
Your HTTP requests should look like:
GET /accounts HTTP/1.1
Authorization: Bearer BEARER-TOKEN-HERE
For administrative functionalities, the value of the token must be the value of admin_auth_token
when the node was launched. When authorizing as a user, it must be the ilp_over_http_incoming_token
which was specified during that user's account creation.
By default, the API is available on port 7770
and it exposes endpoints as specified in this OpenAPIv3 specification (corresponding yml file).
Admin or account-holder only.
In the format of text message of WebSocket, the endpoint will send the following JSON as a payment notification when receiving payments:
{
"to_username": "Receiving account username",
"from_username": "Sending account username",
"destination": "Destination ILP address",
"amount": 1000,
"timestamp": "Receiving time in RFC3339 format",
"sequence": 2,
"connection_closed": false
}
Note that the from_username
corresponds to the account that received the packet on this node, not the original sender.
The sequence
field reports the sequence number of each received packet carrying a payment amount.
A payment notification with amount: 0
and connection_closed: true
will be sent when the last packet (which has a ConnectionClose
frame) has been received. All other payment notifications report an actual payment amount and connection_closed: false
.
Account-holder only.
This endpoint implements BTP, a WebSocket-based protocol for sending and receiving ILP packets. This protocol is specified in IL-RFC 22: Bilateral Transfer Protocol 2.0 (BTP/2.0).
Note this endpoint is the one referred to as ilp_over_btp_url
in the AccountSettings
.