typed-wx-api
Version:
Typed Wechat API
27 lines (26 loc) • 572 B
TypeScript
/**
* @internal
*/
export declare class WxCrypto {
private readonly token;
private readonly key;
private readonly iv;
readonly id: string;
static createNonceStr(): string;
static createTimestamp(): string;
constructor(config: {
token: string;
encodingAESKey: string;
id: string;
});
signature(args: {
timestamp: string;
nonce: string;
encrypt: string;
}): string;
decrypt(text: string): {
message: string;
id: string;
};
encrypt(text: string): string;
}