md5
Generate MD5 hash for any input string securely using the Crypto_MCP server. Simplify data integrity checks and cryptographic processes with reliable hashing.
Instructions
Calculate MD5 hash of a string
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| input | Yes | The input string to hash |
Implementation Reference
- src/service/digest.ts:79-84 (handler)Handler function that computes MD5 hash using DigestUtil.md5 and returns it as text content in MCP format.({ input }) => { const hash = DigestUtil.md5(input); return { content: [{ type: "text", text: hash }], }; }
- src/service/digest.ts:76-78 (schema)Zod input schema defining a single string parameter 'input' for the md5 tool.{ input: z.string().describe("The input string to hash"), },
- src/service/digest.ts:73-85 (registration)Registration of the 'md5' tool on the MCP server, including name, description, schema, and handler.server.tool( "md5", "Calculate MD5 hash of a string", { input: z.string().describe("The input string to hash"), }, ({ input }) => { const hash = DigestUtil.md5(input); return { content: [{ type: "text", text: hash }], }; } );
- src/service/digest.ts:11-14 (helper)Utility function DigestUtil.md5 that calculates the MD5 hash of the input string using CryptoJS library.static md5(input: string): string { const hash = CryptoJS.MD5(input); return hash.toString(); }