• Parameters

    • value: string

    Returns ValidationResult

    0 (NO_PREFIX_MATCHED), 1 (INVALID_CHECKSUM), 2 (INVALID_LENGTH) or 3 (VALID).

    Description

    Used to check if an operation hash is valid.

    Example

    import { validateOperation } from '@mavrykdynamics/taquito-utils';
    const operationHash = 'oo6JPEAy8VuMRGaFuMmLNFFGdJgiaKfnmT1CpHJfKP3Ye5ZahiP'
    const validation = validateOperation(operationHash)
    console.log(validation)
    // This example return 3 which correspond to VALID