PromptisePromptise
Docs
GitHub
Promptise - AI Framework LogoPromptise

The foundation layer for agentic intelligence. Build, secure and operate autonomous AI systems with Promptise Foundry.

pip install promptise

[01] Foundry

  • MCPcast
  • The Promptise Agent
  • Reasoning Engine
  • MCP
  • Agent Runtime
  • Prompt Engineering
  • Execution Engine
  • Agent Identity

[02] Resources

  • Documentation
  • GitHub
  • Guides
  • Learning Paths
  • Questions

[03] Company

  • About
  • Terms of Service
  • Privacy Policy
  • Cookie Policy
  • Subprocessors

© 2026 Promptise by Manser Ventures. All rights reserved.

Open source · Python

← Guides> Topic

Tools and the Model Context Protocol (MCP)

Tools are how an agent acts on the world: read a database, call an API, open a ticket. The Model Context Protocol (MCP) is an open standard for offering those tools to any model or client. An MCP server describes its tools, resources and prompts; a client such as an agent discovers them at runtime and calls them over a transport like stdio or streamable HTTP.

This cluster covers both sides. It starts with what a server exposes and how an agent connects to one, then builds a production MCP server in Python, turns an existing FastAPI app or OpenAPI spec into a server, and adds authentication with JWT and OAuth. The later guides deal with running servers for real: security practices, testing with pytest, keeping the tool list small enough for the model to choose well, caching and circuit breakers, and when a plain CLI is the better choice.

[n.01/02]> 32 guides, in order
  1. 01What Is MCP (Model Context Protocol)? A Developer's GuideWhat MCP is and how it works: hosts, clients, servers, tools, resources, transports and SDK 2.x. Build a small MCP server and connect an agent to it.Beginner · 18 minOct 18, 2026
  2. 02What Is Tool Calling? LLM Function Calling ExplainedWhat tool calling (function calling) is: how an LLM asks your code to run a function, the JSON schema it sees, parallel calls, and how it differs from MCP.Beginner · 7 minOct 18, 2026
  3. 03MCP Tools vs Resources vs Prompts (With Python Examples)When to use an MCP tool, resource or prompt, and how to build each in Python: resource templates, prompt arguments, tests and feeding them to an agent.Intermediate · 20 minOct 11, 2026
  4. 04How to Connect MCP Servers to Your AI Agent in PythonGive your AI agent real tools with the Model Context Protocol. Connect local and remote MCP servers to a Python agent, step by step, with code you can run.Beginner · 12 minOct 11, 2026
  5. 05Build a Production MCP Server in Python (Step by Step)Build an MCP server in Python ready for real agents: typed tools, clear errors, API keys with roles, rate limits, a tamper-evident audit log and tests.Intermediate · 18 minOct 11, 2026
  6. 06MCP Transports: stdio vs Streamable HTTP vs SSE (Python)stdio vs Streamable HTTP vs SSE, shown on the wire with curl, then an MCP server over HTTP in production: Host checks, auth, health checks and scaling.Intermediate · 22 minOct 11, 2026
  7. 07FastAPI MCP Server: Turn Your FastAPI App into MCP ToolsTurn your FastAPI app into an MCP server for Claude and AI agents: fix auth, names and descriptions, gate writes, and test it with a real agent.Intermediate · 22 minOct 11, 2026
  8. 08OpenAPI to MCP: Turn Any REST API into an MCP ServerTurn an OpenAPI spec into a working MCP server in minutes. Read-only by default, human approval on every write, and tested by a real agent.Intermediate · 15 minOct 11, 2026
  9. 09MCP Authentication in Python: API Keys, JWT and OAuthMCP authentication in Python on one server: API keys, JWTs and OAuth client credentials with JWKS, plus roles, scopes, 401s and agent token forwarding.Advanced · 20 minOct 11, 2026
  10. 10Build an Authenticated MCP Server for Your AI Agent (Python)An MCP server authentication tutorial in Python: JWT login and roles, an agent that acts for each user, an attack script and a verified audit log.Intermediate · 25 minOct 15, 2026
  11. 11MCP Security Best Practices: A Checklist for MCP ServersMCP security best practices as a checklist: token audience binding, per-tool scopes, input validation, human approval, rate limits and signed audit logs.Intermediate · 20 minOct 18, 2026
  12. 12Testing MCP Servers in Python: pytest Without a Live ServerTest an MCP server in Python without running it: auth, guards, middleware, resources, prompts, error envelopes and job queues in 35 pytest tests, plus CI.Intermediate · 16 minOct 11, 2026
  13. 13Too Many MCP Tools? LLM Tool Selection, MeasuredWhat 122 tools do to an LLM agent's accuracy, tokens and latency, measured, and how semantic tool selection fixes it in Python, with honest limits.Intermediate · 18 minOct 11, 2026
  14. 14MCP Server Caching, Timeouts and Circuit Breakers in PythonKeep an MCP server fast when its API is flaky: caching, retries with backoff, timeouts, a circuit breaker and limits, with real before and after numbers.Intermediate · 23 minOct 11, 2026
  15. 15MCP vs CLI for AI Agents: Tokens, Security, When to Use EachMCP vs CLI tools for AI agents: where the tokens go, prompt caching, per-user security and when to use each or both, with runnable code and real output.Intermediate · 20 minOct 18, 2026
  16. 16How to Build an AI Agent in Python (2026 Guide)Build an AI agent in Python step by step: write the tool loop, serve tools over MCP, add model fallback, approvals and limits. Runnable code, real output.Beginner · 20 minOct 18, 2026
  17. 17AI Agent Audit Logging: Tamper-Evident Logs in PythonLog every AI agent tool call to an HMAC-chained file, then catch edits, deletions and reordering with one command. Real tamper tests, real output.Intermediate · 15 minOct 11, 2026
  18. 18AI Agent Human in the Loop: Approve Tool Calls in PythonMake your AI agent ask a human before it refunds, emails or deletes. Approve or reject tool calls in Python, with real runs and honest limits.Intermediate · 20 minOct 11, 2026
  19. 19AI Agent Prompt Injection: How to Defend Against ItHow indirect prompt injection reaches AI agents through tool results, and how to defend: untrusted-data prompts, scanners, approval gates, least privilege.Intermediate · 18 minOct 18, 2026
  20. 20AI Agent YAML: Define and Run an Agent From a Config FileDefine an AI agent in a YAML file: model, instructions and MCP servers. Validate it, run it from the CLI or Python, keep secrets out, review it in Git.Intermediate · 18 minOct 11, 2026
  21. 21Build a Multi-Agent System in Python (and When Not To)Build a coordinator that delegates to specialist AI agents in Python, trace every call, and see what a multi-agent system really costs.Intermediate · 24 minOct 11, 2026
  22. 22Context Engineering for AI Agents: Context Window ManagementContext engineering for AI agents in Python: keep what matters in long runs, trim the rest, and cut input tokens 18x. Real token counts per step.Intermediate · 26 minOct 11, 2026
  23. 23How to Deploy an AI Agent with Docker (2026 Guide)Deploy an AI agent with Docker: a Dockerfile, env config and secrets, health checks, graceful shutdown and docker compose with an MCP server. Tested.Intermediate · 18 minOct 18, 2026
  24. 24LLM Supply Chain Security: Models, Packages, Data and ToolsLLM supply chain security as a checklist: inventory models, data and tools, pin and verify hashes, load safe formats, check provenance and plan fallbacks.Intermediate · 9 minOct 18, 2026
  25. 25LLM Tool Rate Limiting: Per-Client Limits for MCP ServersRate limit LLM tool calls per client, tenant and tool on a Python MCP server: a real load test, the error the agent sees, and how to retry it.Intermediate · 14 minOct 11, 2026
  26. 26MCP Long-Running Tasks: Background Jobs in PythonRun slow MCP tools as background jobs in Python: submit, poll progress, retry failures and cancel, with a real agent, real runs and honest limits.Intermediate · 19 minOct 11, 2026
  27. 27MCP Server Monitoring: Prometheus, OpenTelemetry and LogsMonitor an MCP server in Python: Prometheus metrics, JSON logs, OpenTelemetry traces and alerts that show which tools are slow, failing or abused.Intermediate · 20 minOct 11, 2026
  28. 28Python AI Agent Frameworks Compared: Which to Choose (2026)Compare Promptise, LangGraph, CrewAI, Pydantic AI, OpenAI Agents SDK, smolagents and LlamaIndex: features, the same agent in each, and which to choose.Intermediate · 22 minOct 18, 2026
  29. 29Self-Improving AI Agent: Learn From Tool Failures in PythonBuild an AI agent that learns from failed tool calls without fine-tuning. Real before-and-after numbers, plus the risks: bad lessons, leaks, poisoning.Intermediate · 22 minOct 11, 2026
  30. 30AI Agent Identity: Authenticate Agents to MCP ServersGive your AI agent its own verifiable identity: short-lived JWTs from your IdP, checked by MCP servers with JWKS. Real runs, refresh and honest limits.Advanced · 22 minOct 11, 2026
  31. 31Code-Action Agents in Python: One Program vs 37 Tool CallsBuild a code-action agent in Python over an MCP server, test it against ReAct in 60 runs, and see why a tool budget set too low returns wrong answers.Advanced · 15 minOct 15, 2026
  32. 32Multi-Tenant AI Agents: Keep Each Customer's Data ApartBuild a multi-tenant AI agent in Python: per-user tokens, tenant-scoped MCP tools and isolated sessions, with runs proving one tenant can't read another.Advanced · 18 minOct 11, 2026
[n.02/02]> go further

In the documentation

  • What is MCP?docs ↗
  • Building MCP serversdocs ↗
  • MCP clientdocs ↗
  • Auth and securitydocs ↗
  • Testing MCP serversdocs ↗

Other topics

  • Building AI agents in Python→
  • Models and providers→
  • Memory, context and RAG→
  • Agent reasoning patterns→
  • Multi-agent systems→
  • Guardrails and security→
  • Human approvals (human-in-the-loop)→
  • Observability and debugging→
  • Cost control and rate limits→
  • Testing and evals→
  • Runtime, triggers and deployment→
  • Frameworks and comparisons→

Build it with Promptise Foundry.

The code in these guides runs on Promptise Foundry, an open-source Python framework for AI agents and MCP servers.

QuickstartAll guides