技能潮 SkillTide 提交收录
官方说明3 个来源MCP 服务3 天前
zacharypodbela/django-rest-framework-mcp

zacharypodbela/django-rest-framework-mcp

MCP server for Django REST Framework
在 GitHub 查看 ↗直链 · 无中转页
来源明细
收录自 abordage/awesome-mcp 榜单(我们从中收集的条目之一) · 条目类型:MCP 服务
收录与活跃
收录于 2026-10-14 · 最近见到 2026-10-16 · 共见到 4 次 · 被 3 个来源列出
评分构成
综合分 303 · 3 个来源 · mcp
常见问题(答案都来自我们的记录)
怎么安装?
我们【没有】从该仓库取到安装命令(我们的 install 覆盖率只有约 4%)。请看它的 README 或 releases 页。
它适合谁 / 用来做什么?
我们把它归在这些标签下: MCP 服务。标签来自条目自身,不是我们强加的分类。
谁维护它、还在更新吗?
我们收录于 2026-10-14;最近见到 2026-10-16。这里没有"官方认证"或"质量评级"——我们只记录来源与时间。
第三方质量标记

Django REST Framework MCP

以下摘录自该仓库的 README(片段) · 在 GitHub 读完整 README →

django-rest-framework-mcp allows you to spin up MCP servers that expose your Django Rest Framework APIs as MCP tools with just a few lines of code.
Supercharge your admin workflows (and make developing Admin interfaces a thing of the past):
- "Deactivate josh@gmail.com's account" → Actually deactivates it
- "Extend jack@teams.com's free trial by 1 week" → Updates their plan
- "How many new users joined week-over-week?" → Returns real data → LLMs can quickly create graphs _(no more complex FE graphing libraries needed)_
Or transform your traditional, boring SaaS UX with conversational interactions:
- Old way: User Clicks "Manage", Clicks "My Posts", Clicks a post from the list, Clicks "Edit", changes the title, Clicks "Save"
- With Django Rest Framework MCP: "Can you rename my post from 'Beginners Guide to Django' to 'Django 101'?"
Quick Start
1. Install the package:
2. Add to your INSTALLED_APPS:
3. Add the MCP endpoint to your urls.py:
4. Transform any DRF ViewSet into MCP tools with a single decorator:
When @mcp_viewset is applied to a ViewSet class that inherits from GenericViewSet (such as ModelViewSet or ReadOnlyModelViewSet), any of the following methods that are defined will be automatically exposed as MCP tools:
- list -> List customers with customers_list tool.
- retrieve -> Retrieve a customer with customers_retrieve tool.
- create -> Create new customers with customers_create tool.
- update -> Update customers with customers_update tool. (All fields must be passed in)
- partial_update -> Update customers with customers_partial_update tool. (A subset of fields can be passed in)
- destroy -> Delete customers with customers_destroy tool.
For each tool the library automatically:
- Generates tool schemas from your DRF serializers
- Preserves your existing permissions, authentication, and filtering
- Returns context rich error messages to guide LLMs
(See: _Custom Actions_ below for more info on how to expose additional endpoints you created using the @action decorator as tools).
5. Connect any MCP client to http://localhost:8000/mcp/ and try it out!
Important Differences between MCP Requests and API Requests
MCP requests do not go through the full DRF request lifecycle.
**View lifecycle methods that will be called:**
- **perform_authentication(request)** - Called unless BYPASS_VIEWSET_AUTHENTICATION = True
- **check_permissions(request)** - Called unless BYPASS_VIEWSET_PERMISSIONS = True
- **check_throttles(request)** - Always called (no bypass option)
- **determine_version(request, \*args, **kwargs)\*\* - Always called to set request versioning
**View lifecycle methods that won't be called:**
- **dispatch(request, args, kwargs)** - will not be called since we don't use HTTP method+path routing.
- **initialize_request(request, args, kwargs)** will not be called. We do create a rest_framework.requests.Request from the django.http.HttpRequest, but not using this handler.
- **initial(request, args, kwargs)** - will not be called.
- **perform_content_negotiation(request)** - will not be called since MCP/JSON-RPC dictates the input and output format.
- **finalize_response(request, response, args, kwargs)** will not be called.
- **handle_exception(exc)** will not be called in the event of an exception\*.
**Additional considerations:**
- The request object will be missing API-specific properties like method, path, or path_info since it wasn't created from an actual HTTP API call
- Content negotiation is bypassed since MCP always uses JSON
Connecting a STDIO MCP Client
Right now, the MCP server is only open to HTTP transport. To support stdio transport, you'll need a bridge. We recommend mcp-remote.
Example: Connect to Claude Desktop
Follow these instructions to use mcp-remote to connect to Claude Desktop:
1. Install mcp-remote: npm install -g mcp-remote
2. Open Claude MCP Desktop Configuration by going to Settings > Developer > Edit Config and add your server configuration:
3. Restart Claude Desktop and test your tools
**Development Tip:** LLMs can be surprisingly effective at “manually” testing your MCP tools and uncovering bugs. In Claude Desktop, try a prompt like: _"I'm developing a new set of MCP tools locally. Please extensively test them — including coming up with complex edge cases to try - and look for unexpected behavior or bugs. Make at least 30 tool calls."_
来源
awesome · https://github.com/zacharypodbela/django-rest-framework-mcp
按领域浏览
MCP 服务
收录于
昨天

更多MCP 服务

查看MCP 服务全部 5,525 条 →

所属领域与标签

每个标签都能点进去看同类的全部条目。数字是当前库里的真实条数。

浏览全部领域 →

← 返回索引