UNPKG

@martcarrefour/robokassa

Version:

Robokassa Node.JS integration (Note: Original repository is now actively maintained)

10 lines (6 loc) 209 B
import { createHash } from 'crypto'; export const calculateHash = (hashAlgorithm: string, value: string) => { const hash = createHash(hashAlgorithm); hash.update(value); return hash.digest('hex'); };