Master tool design for AI agents and the Model Context Protocol. From fundamentals to building MCP servers, security, and production patterns.