{ "$schema": "../../rpc-schema-draft.json", "type": "object", "additionalProperties": false, "notification": "channel_state_changed", "title": "Notification for channel state change", "description": [ "The **channel_state_changed** informs whenever the state of the channel has been updated." ], "added": "pre-v0.10.1", "request": {}, "response": { "required": [ "peer_id", "channel_id", "timestamp", "new_state", "cause" ], "properties": { "peer_id": { "type": "pubkey", "description": [ "The peer id of the channel." ], "added": "pre-v0.10.1" }, "channel_id": { "type": "hash", "description": [ "The channel id of the channel." ], "added": "pre-v0.10.1" }, "short_channel_id": { "type": "short_channel_id", "description": [ "The short channel id of the channel. If the channel is not yet confirmed, this field will be null." ], "added": "pre-v0.10.1" }, "timestamp": { "type": "string", "description": [ "The timestamp of the state change." ], "added": "pre-v0.10.1" }, "old_state": { "type": "string", "enum": [ "OPENINGD", "CHANNELD_AWAITING_LOCKIN", "CHANNELD_NORMAL", "CHANNELD_SHUTTING_DOWN", "CLOSINGD_SIGEXCHANGE", "CLOSINGD_COMPLETE", "AWAITING_UNILATERAL", "FUNDING_SPEND_SEEN", "ONCHAIN", "DUALOPEND_OPEN_INIT", "DUALOPEND_AWAITING_LOCKIN", "CHANNELD_AWAITING_SPLICE", "DUALOPEND_OPEN_COMMITTED", "DUALOPEND_OPEN_COMMIT_READY" ], "description": [ "The channel state, in particular \"CHANNELD_NORMAL\" and \"CHANNELD_AWAITING_SPLICE\" mean the channel can be used normally.", "The deprecated value 'unknown' is also present for new channels: after v26.03 this field will be omitted instead." ], "added": "pre-v0.10.1" }, "new_state": { "type": "string", "enum": [ "OPENINGD", "CHANNELD_AWAITING_LOCKIN", "CHANNELD_NORMAL", "CHANNELD_SHUTTING_DOWN", "CLOSINGD_SIGEXCHANGE", "CLOSINGD_COMPLETE", "AWAITING_UNILATERAL", "FUNDING_SPEND_SEEN", "ONCHAIN", "DUALOPEND_OPEN_INIT", "DUALOPEND_AWAITING_LOCKIN", "CHANNELD_AWAITING_SPLICE", "DUALOPEND_OPEN_COMMITTED", "DUALOPEND_OPEN_COMMIT_READY", "CLOSED" ], "description": [ "The channel state, in particular \"CHANNELD_NORMAL\" and \"CHANNELD_AWAITING_SPLICE\" mean the channel can be used normally", "Note: *CLOSED* state was only added in v25.12." ], "added": "pre-v0.10.1" }, "cause": { "type": "string", "enum": [ "unknown", "local", "user", "remote", "protocol", "onchain" ], "description": [ "The cause of the state change." ], "added": "pre-v0.10.1" }, "message": { "type": "string", "description": [ "The state change message." ], "added": "pre-v0.10.1" } } } }