@node-lightning/wire
Version:
Lightning Network Wire Protocol
44 lines (43 loc) • 1.61 kB
TypeScript
/// <reference types="node" />
import { ChannelId } from "@node-lightning/core";
import { MessageType } from "../MessageType";
import { IWireMessage } from "./IWireMessage";
/**
* The `funding_signed` message is sent by the channel acceptor after
* they have recieved a `funding_created` message from the initiator.
* This message includes the signature for the initiator's first
* commitment transaction. After the initiator receives this message
* the channel can be broadcast to the Bitcoin network as both
* participants can spend the outputs of the funding transaction. This
* message also is the first instance of the `channel_id` and both sides
* can transition from using the `temporary_channel_id` to the actual
* `channel_id`.
*/
export declare class FundingSignedMessage implements IWireMessage {
static type: MessageType;
/**
* Deserializes the funding_signed message
* @param buf
* @returns
*/
static deserialize(buf: Buffer): FundingSignedMessage;
/**
* The type for message. funding_signed = 35
*/
readonly type: MessageType;
/**
* ChannelId generated from the funding transactions outpoint.
*/
channelId: ChannelId;
/**
* Signature for the counterpary's first commitment transaction.
* This signature allows the counterparty to spend the commitment
* using their own signature. The signature must be 64-bytes
* representing the 32-byte (r,s) values for an ECDSA signature.
*/
signature: Buffer;
/**
* Serializes the message into a Buffer
*/
serialize(): Buffer;
}