def METHOD_NAME(seq, to, value, data, key):
    keys = KeyAPI()
    comb = seq.to_bytes(32, "big") + b"\x00" * 12 + to + value.to_bytes(32, "big") + data
    h1 = keccak(comb)
    h2 = keccak(b"\x19Ethereum Signed Message:\n32" + h1)
    sig = keys.ecdsa_sign(h2, key)
    return [28 if sig.v == 1 else 27, sig.r, sig.s]