Skip to content
This repository has been archived by the owner on Jun 23, 2019. It is now read-only.

Commit

Permalink
📝 Minor fix
Browse files Browse the repository at this point in the history
  • Loading branch information
motss committed Mar 17, 2018
1 parent bbc7ade commit 7dc6070
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -169,15 +169,15 @@ ___

### sign(rawData, options)

- `rawData` <[string][string-mdn-url]> Raw data payload to be signed.
- `rawData` <`T`> Raw data payload in the type of `T`.
- `options` <[SignaturOptions][signaturoptions-url]> Options for signing the payload.
- returns: <[Promise][promise-mdn-url]&lt;[string][string-mdn-url]&gt;> Promise which resolves with a URL-safe base64 encoded HMAC-SHA256 signature that encrypts the raw data payload with a required secret key.

### unsign(signature, options)

- `signature` <[string][string-mdn-url]> URL-safe signature.
- `options` <[SignaturOptions][signaturoptions-url]> Options for signing the payload.
- returns: <[Promise][promise-mdn-url]&lt;[string][string-mdn-url]&gt;> Promise which resolves with decoded data payload.
- returns: <[Promise][promise-mdn-url]&lt;`T`&gt;> Promise which resolves with decoded data payload in the type of `T`.

Throws a custom error object for bad signature in the type of [SignaturOptionsError][signaturoptionserror-url]. The error object can be customized via the `options[error]`.

Expand Down

0 comments on commit 7dc6070

Please sign in to comment.