Skip to main content
Glama
jphyqr

HashBuilds Secure Prompts

by jphyqr

verify_secure_prompt

Check prompt security by ID to identify hidden injections, data exfiltration patterns, and jailbreak attempts, then view risk levels and verification status.

Instructions

Verify an existing secure prompt by its ID. Returns the security scan results, risk level, and verification status.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
promptIdYesThe ID of the secure prompt to verify

Implementation Reference

  • MCP tool handler switch case for 'verify_secure_prompt'. Validates input and delegates to verifyPrompt function.
    case "verify_secure_prompt": { const typedArgs = args as { promptId: string }; if (!typedArgs.promptId) { throw new McpError(ErrorCode.InvalidParams, "promptId is required"); } const result = await verifyPrompt(typedArgs); return { content: [ { type: "text", text: JSON.stringify(result, null, 2), }, ], }; }
  • Core implementation function that fetches verification data from the HashBuilds API for the given prompt ID.
    async function verifyPrompt(args: { promptId: string }): Promise<{ valid: boolean; id?: string; riskLevel?: string; verified?: boolean; normalizedText?: string; scanResults?: object; lastVerified?: string; error?: string; }> { try { const response = await fetch(`${API_BASE}/verify/${args.promptId}`); const result = await response.json(); if (!response.ok) { return { valid: false, error: result.error || "Verification failed" }; } return { valid: true, id: result.id, riskLevel: result.riskLevel, verified: result.verified, normalizedText: result.normalizedText, scanResults: result.scanResults, lastVerified: result.lastVerified, }; } catch (error) { return { valid: false, error: error instanceof Error ? error.message : "Network error", }; } }
  • JSON schema defining the input parameters for the verify_secure_prompt tool.
    inputSchema: { type: "object", properties: { promptId: { type: "string", description: "The ID of the secure prompt to verify", }, }, required: ["promptId"], },
  • src/index.ts:424-438 (registration)
    Registration of the verify_secure_prompt tool in the ListTools response, including name, description, and schema.
    name: "verify_secure_prompt", description: "Verify an existing secure prompt by its ID. " + "Returns the security scan results, risk level, and verification status.", inputSchema: { type: "object", properties: { promptId: { type: "string", description: "The ID of the secure prompt to verify", }, }, required: ["promptId"], }, },

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/jphyqr/secure-prompts-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server