sign( data: string | Uint8Array<ArrayBufferLike>, key: string, opts?: Partial<{ algorithm: "sha-256" | "sha-512" }>,): Promise<string> Parameters
- data: string | Uint8Array<ArrayBufferLike>
- key: string
Optional
opts: Partial<{ algorithm: "sha-256" | "sha-512" }>
Returns Promise<string>
Sign the given data and return the signature as a string.