nodejs-cryptomus
Version:
A comprehensive Node.js client for the Cryptomus API
18 lines (17 loc) • 549 B
TypeScript
/**
* Generate signature for API requests
*
* @param payload - Request payload
* @param apiKey - API key
* @returns Generated signature
*/
export declare function generateSignature(payload: Record<string, any>, apiKey: string): string;
/**
* Verify webhook signature
*
* @param payload - Webhook payload
* @param signature - Signature from webhook headers
* @param apiKey - API key
* @returns Whether the signature is valid
*/
export declare function verifyWebhookSignature(payload: string, signature: string, apiKey: string): boolean;