2018-12-20 13:42:28 +03:00
|
|
|
syntax = "proto3";
|
|
|
|
|
2019-01-03 21:15:14 +03:00
|
|
|
import "google/api/annotations.proto";
|
|
|
|
import "rpc.proto";
|
|
|
|
|
2018-12-20 13:42:28 +03:00
|
|
|
package invoicesrpc;
|
|
|
|
|
|
|
|
option go_package = "github.com/lightningnetwork/lnd/lnrpc/invoicesrpc";
|
|
|
|
|
|
|
|
// Invoices is a service that can be used to create, accept, settle and cancel
|
|
|
|
// invoices.
|
|
|
|
service Invoices {
|
2019-01-03 21:15:14 +03:00
|
|
|
/**
|
|
|
|
SubscribeSingleInvoice returns a uni-directional stream (server -> client)
|
|
|
|
to notify the client of state transitions of the specified invoice.
|
|
|
|
Initially the current invoice state is always sent out.
|
|
|
|
*/
|
|
|
|
rpc SubscribeSingleInvoice (lnrpc.PaymentHash) returns (stream lnrpc.Invoice);
|
2019-01-11 13:19:16 +03:00
|
|
|
|
|
|
|
/**
|
|
|
|
CancelInvoice cancels a currently open invoice. If the invoice is already
|
|
|
|
canceled, this call will succeed. If the invoice is already settled, it will
|
|
|
|
fail.
|
|
|
|
*/
|
|
|
|
rpc CancelInvoice(CancelInvoiceMsg) returns (CancelInvoiceResp);
|
2018-12-20 13:42:28 +03:00
|
|
|
}
|
|
|
|
|
2019-01-11 13:19:16 +03:00
|
|
|
message CancelInvoiceMsg {
|
|
|
|
/// Hash corresponding to the invoice to cancel.
|
|
|
|
bytes payment_hash = 1;
|
|
|
|
}
|
|
|
|
message CancelInvoiceResp {}
|