You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Let's add an enum field to receive APIs (blind_receive and witness_receive) to allow the user to have more control over the transfer, based on the RGB amount being received.
The enum should be defined as:
/// Choice of policy to apply when receiving a transfer, based on the RGB amountpubenumReceiveAmount{/// Any received amount will be accepted, regardless of the amount that has been specified in the invoiceWhatever,// If the received amount is different from the requested one the transfer should be refused. This value is possible only when setting an amount into the invoiceExact,/// If the received amount is lower than the requested one the transfer should be refused. This value is possible only when setting an amount into the invoiceAtLeast,}
As the enum documentation says, if the user specifies ReceiveAmount::Exact or ReceiveAmount::AtLeast then the optional amount field of the receive APIs should be set, otherwise an Error::NoReceiveAmount error (to be added) should be returned.
The text was updated successfully, but these errors were encountered:
Let's add an enum field to receive APIs (
blind_receive
andwitness_receive
) to allow the user to have more control over the transfer, based on the RGB amount being received.The enum should be defined as:
As the enum documentation says, if the user specifies
ReceiveAmount::Exact
orReceiveAmount::AtLeast
then the optionalamount
field of the receive APIs should be set, otherwise anError::NoReceiveAmount
error (to be added) should be returned.The text was updated successfully, but these errors were encountered: