pub enum APIError {
APIMisuseError {
err: &'static str,
},
FeeRateTooHigh {
err: String,
feerate: u64,
},
RouteError {
err: &'static str,
},
ChannelUnavailable {
err: &'static str,
},
MonitorUpdateFailed,
}
Indicates an error on the client's part (usually some variant of attempting to use too-low or
too-high values)
Indicates the API was wholly misused (see err for more). Cases where these can be returned
are documented, but generally indicates some precondition of a function was violated.
Fields of APIMisuseError
A human-readable error message
Due to a high feerate, we were unable to complete the request.
For example, this may be returned if the feerate implies we cannot open a channel at the
requested value, but opening a larger channel would succeed.
Fields of FeeRateTooHigh
A human-readable error message
The feerate which was too high.
A malformed Route was provided (eg overflowed value, node id mismatch, overly-looped route,
too-many-hops, etc).
Fields of RouteError
A human-readable error message
We were unable to complete the request as the Channel required to do so is unable to
complete the request (or was not found). This can take many forms, including disconnected
peer, channel at capacity, channel shutting down, etc.
Fields of ChannelUnavailable
A human-readable error message
An attempt to call add_update_monitor returned an Err (ie you did this!), causing the
attempted action to fail.
Formats the value using the given formatter. Read more
🔬 This is a nightly-only experimental API. (try_from
)
The type returned in the event of a conversion error.
🔬 This is a nightly-only experimental API. (try_from
)
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more
🔬 This is a nightly-only experimental API. (try_from
)
The type returned in the event of a conversion error.
🔬 This is a nightly-only experimental API. (try_from
)
🔬 This is a nightly-only experimental API. (get_type_id
)
this method will likely be replaced by an associated static