API ReferenceValidationVariable
redeemLOCRules
const redeemLOCRules: ValidationRule<RedeemLOCsParams>[];Validation rules for the redeemLOC operation.
Single inline rule covering the redemptions array:
- Sync: amount > 0, destination address format per redemption
- Async: LOC existence, not expired, amount <= credited, authorization
Authorization logic (per redemption):
- If beneficiaryAuthorization provided or multi-redemption → verify signature
- Else signer must be the LOC’s beneficiary
Second rule covering supplied oracle price updates:
- Async: any
oraclePriceUpdatethe caller handed in must still be fresh