
dkmaker/mcp-rest-api
Developer toolsЭта страница переведена автоматически. Технические детали смотрите в оригинале. Открыть оригинал
dkmaker/mcp-rest-API — это кандидат-сервер MCP, импортированный из https://github.com/dkmaker/mcp-rest-api.
Обзор
dkmaker/mcp-rest-API — это кандидат-сервер MCP, импортированный из https://github.com/dkmaker/mcp-rest-api.
Обзор (машинный перевод)
MCP-сервер на базе TypeScript, который позволяет тестировать REST API через Claude, Cline и другие MCP-клиенты. Этот инструмент позволяет тестировать и взаимодействовать с любыми конечными точками REST API непосредственно из вашей среды разработки.
Установка
Установите пакет глобально:
Конфигурация
Инструкции Клайн
Чтобы Клайн понимал, как эффективно использовать этот инструмент, добавьте в свои пользовательские инструкции (Настройки > Пользовательские инструкции):
Конфигурация сервера MCP
Хотя эти инструкции предназначены для Cline, сервер должен работать с любой реализацией MCP. Настройте на основе вашей операционной системы:
Окна
⚠️ ВАЖНО: Из-за известной проблемы с разрешением путей Windows (проблема #40) вам нужно использовать полный путь вместо %APPDATA%.
Добавить к C:\Users\ \AppData\Roaming\Code\User\globalStorage\saoudrizwan.claude-dev\settings\cline_mcp_settings.json:
macOS
Добавить к ~/Library/Application Support/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json:
Примечание: замените переменные среды на ваши фактические значения. Настраивайте только один метод аутентификации одновременно:
- Базовая аутентификация (имя пользователя/пароль)
Эта страница переведена автоматически. Технические детали смотрите в оригинале.
README
Показан фрагмент оригинального README. Открыть оригинал.
MCP REST API Tester
A TypeScript-based MCP server that enables testing of REST APIs through Claude, Cline and other MCP clients. This tool allows you to test and interact with any REST API endpoints directly from your development environment.
Installation
Install the package globally:
npm install -g dkmaker-mcp-rest-api
Configuration
Cline Custom Instructions
To ensure Cline understands how to effectively use this tool, add the following to your Cline custom instructions (Settings > Custom Instructions):
# REST API Testing Instructions
The `test_request` tool enables testing, debugging, and interacting with REST API endpoints. The tool provides comprehensive request/response information and handles authentication automatically.
## When to Use
- Testing specific API endpoints
- Debugging API responses
- Verifying API functionality
- Checking response times
- Validating request/response formats
- Testing local development servers
- Testing API sequences
- Verifying error handling
## Key Features
- Supports GET, POST, PUT, DELETE, PATCH methods
- Handles authentication (Basic, Bearer, API Key)
- Normalizes endpoints automatically
- Provides detailed response information
- Configurable SSL verification and response limits
## Resources
The following resources provide detailed documentation:
- examples: Usage examples and common patterns
- response-format: Response structure and fields
- config: Configuration options and setup guide
Access these resources to understand usage, response formats, and configuration options.
## Important Notes
- Review API implementation for expected behavior
- Handle sensitive data appropriately
- Consider rate limits and API constraints
- Restart server after configuration changes
MCP Server Configuration
While these instructions are for Cline, the server should work with any MCP implementation. Configure based on your operating system:
Windows
⚠️ IMPORTANT: Due to a known issue with Windows path resolution (issue #40), you must use the full path instead of %APPDATA%.
Add to C:\Users\\AppData\Roaming\Code\User\globalStorage\saoudrizwan.claude-dev\settings\cline_mcp_settings.json:
{
"mcpServers": {
"rest-api": {
"command": "node",
"args": [
"C:/Users//AppData/Roaming/npm/node_modules/dkmaker-mcp-rest-api/build/index.js"
],
"env": {
Установка
npx -y dkmaker-mcp-rest-apiКонфигурация
{
"mcpServers": {
"rest-api": {
"command": "node",
"args": [
"C:/Users/<YourUsername>/AppData/Roaming/npm/node_modules/dkmaker-mcp-rest-api/build/index.js"
],
"env": {
"REST_BASE_URL": "https://api.example.com",
// Basic Auth
"AUTH_BASIC_USERNAME": "your-username",
"AUTH_BASIC_PASSWORD": "your-password",
// OR Bearer Token
"AUTH_BEARER": "your-token",
// OR API Key
"AUTH_APIKEY_HEADER_NAME": "X-API-Key",
"AUTH_APIKEY_VALUE": "your-api-key",
// SSL Verification (enabled by default)
"REST_ENABLE_SSL_VERIFY": "false", // Set to false to disable SSL verification for self-signed certificates
// Response Size Limit (optional, defaults to 10000 bytes)
"REST_RESPONSE_SIZE_LIMIT": "10000", // Maximum response size in bytes
// Custom Headers (optional)
"HEADER_X-API-Version": "2.0",
"HEADER_Custom-Client": "my-client",
"HEADER_Accept": "application/json"
}
}
}
}