json-signature
v1.1.0
Published
This package enables the generation of unique hash signatures for provided payloads. It normalise json key order so the same payload data with different key order generates same key.
Downloads
139
Maintainers
Readme
JSON-Signature Generator
This package enables the generation of unique hash signatures for provided payloads. It normalise json key order so the same payload data with different key order generates same key.
Installation
You can install this package via pip:
npm i json-signature
Usage
import { JsonSignature } from "json-signature";
console.log(
JsonSignature.GetSignatureForData(
{
key1: "value1",
key2: "value2",
array_key: [1, 2, 3],
},
{
hashType: "sha256",
digestType: "hex",
ignoreArrayOrder: true,
}
)
);
Contribution
Contributions are welcome! If you encounter issues or have suggestions for improvements, feel free to open an issue or submit a pull request on GitHub.
License
This package is licensed under the MIT License.
Contact
For inquiries or support, please contact [email protected].