mcp-proxy-adapter 6.4.10__py3-none-any.whl → 6.4.11__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- mcp_proxy_adapter/examples/run_full_test_suite.py +122 -0
- mcp_proxy_adapter/examples/setup_test_environment.py +12 -11
- mcp_proxy_adapter/version.py +1 -1
- mcp_proxy_adapter-6.4.11.dist-info/METADATA +156 -0
- {mcp_proxy_adapter-6.4.10.dist-info → mcp_proxy_adapter-6.4.11.dist-info}/RECORD +8 -16
- mcp_proxy_adapter-6.4.11.dist-info/top_level.txt +1 -0
- mcp_proxy_adapter/examples/basic_framework/roles.json +0 -21
- mcp_proxy_adapter/examples/full_application/roles.json +0 -21
- mcp_proxy_adapter/examples/generate_comprehensive_config.py +0 -177
- mcp_proxy_adapter/examples/test_mcp_adapter.py +0 -207
- mcp_proxy_adapter/schemas/base_schema.json +0 -114
- mcp_proxy_adapter/schemas/openapi_schema.json +0 -314
- mcp_proxy_adapter/utils/config_generator.py +0 -1167
- mcp_proxy_adapter-6.4.10.dist-info/METADATA +0 -680
- mcp_proxy_adapter-6.4.10.dist-info/top_level.txt +0 -2
- mcp_proxy_adapter_issue_package/demonstrate_issue.py +0 -208
- {mcp_proxy_adapter-6.4.10.dist-info → mcp_proxy_adapter-6.4.11.dist-info}/WHEEL +0 -0
- {mcp_proxy_adapter-6.4.10.dist-info → mcp_proxy_adapter-6.4.11.dist-info}/entry_points.txt +0 -0
@@ -1,207 +0,0 @@
|
|
1
|
-
#!/usr/bin/env python3
|
2
|
-
"""
|
3
|
-
One-Command Test Runner for MCP Proxy Adapter
|
4
|
-
This script creates a fresh test environment and runs all tests.
|
5
|
-
Author: Vasiliy Zdanovskiy
|
6
|
-
email: vasilyvz@gmail.com
|
7
|
-
|
8
|
-
Usage:
|
9
|
-
python test_mcp_adapter.py
|
10
|
-
"""
|
11
|
-
import asyncio
|
12
|
-
import os
|
13
|
-
import subprocess
|
14
|
-
import sys
|
15
|
-
import time
|
16
|
-
from pathlib import Path
|
17
|
-
|
18
|
-
|
19
|
-
def run_command(cmd, description, cwd=None, timeout=300):
|
20
|
-
"""Run a command and return success status."""
|
21
|
-
print(f"🚀 {description}...")
|
22
|
-
try:
|
23
|
-
result = subprocess.run(
|
24
|
-
cmd,
|
25
|
-
shell=True,
|
26
|
-
cwd=cwd,
|
27
|
-
capture_output=True,
|
28
|
-
text=True,
|
29
|
-
timeout=timeout
|
30
|
-
)
|
31
|
-
if result.returncode == 0:
|
32
|
-
print(f"✅ {description} completed successfully")
|
33
|
-
return True
|
34
|
-
else:
|
35
|
-
print(f"❌ {description} failed")
|
36
|
-
if result.stderr.strip():
|
37
|
-
print(f"🔍 Error: {result.stderr.strip()}")
|
38
|
-
return False
|
39
|
-
except subprocess.TimeoutExpired:
|
40
|
-
print(f"⏰ {description} timed out after {timeout} seconds")
|
41
|
-
return False
|
42
|
-
except Exception as e:
|
43
|
-
print(f"❌ {description} failed with exception: {e}")
|
44
|
-
return False
|
45
|
-
|
46
|
-
|
47
|
-
def main():
|
48
|
-
"""Main function to run complete test suite."""
|
49
|
-
print("=" * 80)
|
50
|
-
print("🎯 MCP PROXY ADAPTER - ONE-COMMAND TEST SUITE")
|
51
|
-
print("=" * 80)
|
52
|
-
print("This script will create a fresh test environment and run all tests.")
|
53
|
-
print("=" * 80)
|
54
|
-
|
55
|
-
# Get current directory
|
56
|
-
current_dir = Path.cwd()
|
57
|
-
print(f"📁 Working directory: {current_dir}")
|
58
|
-
|
59
|
-
# Clean up any existing test environment
|
60
|
-
test_env_dir = current_dir / "test_environment"
|
61
|
-
if test_env_dir.exists():
|
62
|
-
print("🧹 Cleaning up existing test environment...")
|
63
|
-
import shutil
|
64
|
-
shutil.rmtree(test_env_dir)
|
65
|
-
print("✅ Cleaned up existing test environment")
|
66
|
-
|
67
|
-
# Step 1: Setup test environment
|
68
|
-
print("\n" + "=" * 60)
|
69
|
-
print("STEP 1: SETTING UP TEST ENVIRONMENT")
|
70
|
-
print("=" * 60)
|
71
|
-
|
72
|
-
setup_cmd = "python -m mcp_proxy_adapter.examples.setup_test_environment --output-dir test_environment"
|
73
|
-
if not run_command(setup_cmd, "Setting up test environment"):
|
74
|
-
print("❌ Failed to setup test environment. Aborting.")
|
75
|
-
return False
|
76
|
-
|
77
|
-
# Step 2: Generate test configurations
|
78
|
-
print("\n" + "=" * 60)
|
79
|
-
print("STEP 2: GENERATING TEST CONFIGURATIONS")
|
80
|
-
print("=" * 60)
|
81
|
-
|
82
|
-
config_cmd = "python -m mcp_proxy_adapter.examples.generate_test_configs --output-dir test_environment/configs"
|
83
|
-
if not run_command(config_cmd, "Generating test configurations"):
|
84
|
-
print("❌ Failed to generate configurations. Aborting.")
|
85
|
-
return False
|
86
|
-
|
87
|
-
# Step 3: Fix mTLS configurations and certificates
|
88
|
-
print("\n" + "=" * 60)
|
89
|
-
print("STEP 3: FIXING mTLS CONFIGURATIONS AND CERTIFICATES")
|
90
|
-
print("=" * 60)
|
91
|
-
|
92
|
-
# Fix certificate naming
|
93
|
-
cert_fixes = [
|
94
|
-
"ln -sf mcp_proxy_adapter_test_ca_ca.crt certs/mcp_proxy_adapter_ca_ca.crt",
|
95
|
-
"ln -sf admin-client_client.crt certs/admin_cert.pem",
|
96
|
-
"ln -sf admin-client_client.key certs/admin_key.pem",
|
97
|
-
"ln -sf admin-client_client.crt certs/user_cert.pem",
|
98
|
-
"ln -sf admin-client_client.key certs/user_key.pem"
|
99
|
-
]
|
100
|
-
|
101
|
-
for fix_cmd in cert_fixes:
|
102
|
-
run_command(fix_cmd, f"Fixing certificate: {fix_cmd.split()[-1]}", cwd=test_env_dir)
|
103
|
-
|
104
|
-
# Fix mTLS configurations
|
105
|
-
print("🔧 Fixing mTLS configurations...")
|
106
|
-
|
107
|
-
# Read and fix mtls_with_roles.json
|
108
|
-
mtls_with_roles_path = test_env_dir / "configs" / "mtls_with_roles.json"
|
109
|
-
if mtls_with_roles_path.exists():
|
110
|
-
try:
|
111
|
-
import json
|
112
|
-
with open(mtls_with_roles_path, 'r') as f:
|
113
|
-
config = json.load(f)
|
114
|
-
|
115
|
-
# Add default_protocol if missing
|
116
|
-
if "protocols" in config and "default_protocol" not in config["protocols"]:
|
117
|
-
config["protocols"]["default_protocol"] = "mtls"
|
118
|
-
|
119
|
-
# Add client certificate paths if missing
|
120
|
-
if "ssl" in config:
|
121
|
-
if "client_cert_file" not in config["ssl"]:
|
122
|
-
config["ssl"]["client_cert_file"] = "certs/admin_cert.pem"
|
123
|
-
if "client_key_file" not in config["ssl"]:
|
124
|
-
config["ssl"]["client_key_file"] = "certs/admin_key.pem"
|
125
|
-
|
126
|
-
with open(mtls_with_roles_path, 'w') as f:
|
127
|
-
json.dump(config, f, indent=2)
|
128
|
-
print("✅ Fixed mtls_with_roles.json")
|
129
|
-
except Exception as e:
|
130
|
-
print(f"⚠️ Warning: Failed to fix mtls_with_roles.json: {e}")
|
131
|
-
|
132
|
-
# Read and fix mtls_no_roles.json
|
133
|
-
mtls_no_roles_path = test_env_dir / "configs" / "mtls_no_roles.json"
|
134
|
-
if mtls_no_roles_path.exists():
|
135
|
-
try:
|
136
|
-
import json
|
137
|
-
with open(mtls_no_roles_path, 'r') as f:
|
138
|
-
config = json.load(f)
|
139
|
-
|
140
|
-
# Add UUID if missing
|
141
|
-
if "uuid" not in config:
|
142
|
-
import uuid
|
143
|
-
config["uuid"] = str(uuid.uuid4())
|
144
|
-
|
145
|
-
# Add default_protocol if missing
|
146
|
-
if "protocols" in config and "default_protocol" not in config["protocols"]:
|
147
|
-
config["protocols"]["default_protocol"] = "mtls"
|
148
|
-
|
149
|
-
# Fix certificate paths in security.ssl section
|
150
|
-
if "security" in config and "ssl" in config["security"]:
|
151
|
-
ssl_config = config["security"]["ssl"]
|
152
|
-
ssl_config["server_cert_file"] = "certs/localhost_server.crt"
|
153
|
-
ssl_config["server_key_file"] = "keys/localhost_server.key"
|
154
|
-
ssl_config["ca_cert_file"] = "certs/mcp_proxy_adapter_test_ca_ca.crt"
|
155
|
-
ssl_config["client_cert_file"] = "certs/admin_cert.pem"
|
156
|
-
ssl_config["client_key_file"] = "certs/admin_key.pem"
|
157
|
-
|
158
|
-
with open(mtls_no_roles_path, 'w') as f:
|
159
|
-
json.dump(config, f, indent=2)
|
160
|
-
print("✅ Fixed mtls_no_roles.json")
|
161
|
-
except Exception as e:
|
162
|
-
print(f"⚠️ Warning: Failed to fix mtls_no_roles.json: {e}")
|
163
|
-
|
164
|
-
# Step 4: Run security tests
|
165
|
-
print("\n" + "=" * 60)
|
166
|
-
print("STEP 4: RUNNING SECURITY TESTS")
|
167
|
-
print("=" * 60)
|
168
|
-
|
169
|
-
test_cmd = "python -m mcp_proxy_adapter.examples.run_security_tests"
|
170
|
-
test_success = run_command(test_cmd, "Running security tests", cwd=test_env_dir, timeout=600)
|
171
|
-
|
172
|
-
# Step 5: Show final results
|
173
|
-
print("\n" + "=" * 80)
|
174
|
-
print("🎉 ONE-COMMAND TEST SUITE FINISHED")
|
175
|
-
print("=" * 80)
|
176
|
-
print("📋 SUMMARY:")
|
177
|
-
print("✅ Test environment created successfully")
|
178
|
-
print("✅ Configurations generated successfully")
|
179
|
-
print("✅ Certificates generated and fixed")
|
180
|
-
print("✅ Security tests executed")
|
181
|
-
print(f"📁 Test environment location: {test_env_dir}")
|
182
|
-
print("\n🔧 Available configurations:")
|
183
|
-
print(" - HTTP: test_environment/configs/http_simple.json")
|
184
|
-
print(" - HTTP + Token: test_environment/configs/http_token.json")
|
185
|
-
print(" - HTTPS: test_environment/configs/https_simple.json")
|
186
|
-
print(" - HTTPS + Token: test_environment/configs/https_token.json")
|
187
|
-
print(" - mTLS: test_environment/configs/mtls_with_roles.json")
|
188
|
-
print("\n📊 Test Results:")
|
189
|
-
if test_success:
|
190
|
-
print("✅ All tests completed successfully")
|
191
|
-
else:
|
192
|
-
print("⚠️ Some tests failed (check output above for details)")
|
193
|
-
print("=" * 80)
|
194
|
-
|
195
|
-
return test_success
|
196
|
-
|
197
|
-
|
198
|
-
if __name__ == "__main__":
|
199
|
-
try:
|
200
|
-
success = main()
|
201
|
-
sys.exit(0 if success else 1)
|
202
|
-
except KeyboardInterrupt:
|
203
|
-
print("\n⚠️ Interrupted by user")
|
204
|
-
sys.exit(1)
|
205
|
-
except Exception as e:
|
206
|
-
print(f"\n❌ Unexpected error: {e}")
|
207
|
-
sys.exit(1)
|
@@ -1,114 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"$schema": "http://json-schema.org/draft-07/schema#",
|
3
|
-
"title": "Base Schema",
|
4
|
-
"description": "Basic schema for validating commands and results",
|
5
|
-
"definitions": {
|
6
|
-
"command": {
|
7
|
-
"type": "object",
|
8
|
-
"properties": {
|
9
|
-
"jsonrpc": {
|
10
|
-
"type": "string",
|
11
|
-
"enum": ["2.0"],
|
12
|
-
"description": "JSON-RPC version"
|
13
|
-
},
|
14
|
-
"method": {
|
15
|
-
"type": "string",
|
16
|
-
"description": "Command name"
|
17
|
-
},
|
18
|
-
"params": {
|
19
|
-
"type": "object",
|
20
|
-
"description": "Command parameters"
|
21
|
-
},
|
22
|
-
"id": {
|
23
|
-
"oneOf": [
|
24
|
-
{"type": "string"},
|
25
|
-
{"type": "integer"},
|
26
|
-
{"type": "null"}
|
27
|
-
],
|
28
|
-
"description": "Request ID"
|
29
|
-
}
|
30
|
-
},
|
31
|
-
"required": ["jsonrpc", "method"]
|
32
|
-
},
|
33
|
-
"success_response": {
|
34
|
-
"type": "object",
|
35
|
-
"properties": {
|
36
|
-
"jsonrpc": {
|
37
|
-
"type": "string",
|
38
|
-
"enum": ["2.0"],
|
39
|
-
"description": "JSON-RPC version"
|
40
|
-
},
|
41
|
-
"result": {
|
42
|
-
"type": "object",
|
43
|
-
"properties": {
|
44
|
-
"success": {
|
45
|
-
"type": "boolean",
|
46
|
-
"enum": [true],
|
47
|
-
"description": "Success flag"
|
48
|
-
},
|
49
|
-
"data": {
|
50
|
-
"type": "object",
|
51
|
-
"description": "Response data"
|
52
|
-
},
|
53
|
-
"message": {
|
54
|
-
"type": "string",
|
55
|
-
"description": "Response message"
|
56
|
-
}
|
57
|
-
},
|
58
|
-
"required": ["success"]
|
59
|
-
},
|
60
|
-
"id": {
|
61
|
-
"oneOf": [
|
62
|
-
{"type": "string"},
|
63
|
-
{"type": "integer"},
|
64
|
-
{"type": "null"}
|
65
|
-
],
|
66
|
-
"description": "Request ID"
|
67
|
-
}
|
68
|
-
},
|
69
|
-
"required": ["jsonrpc", "result"]
|
70
|
-
},
|
71
|
-
"error_response": {
|
72
|
-
"type": "object",
|
73
|
-
"properties": {
|
74
|
-
"jsonrpc": {
|
75
|
-
"type": "string",
|
76
|
-
"enum": ["2.0"],
|
77
|
-
"description": "JSON-RPC version"
|
78
|
-
},
|
79
|
-
"error": {
|
80
|
-
"type": "object",
|
81
|
-
"properties": {
|
82
|
-
"code": {
|
83
|
-
"type": "integer",
|
84
|
-
"description": "Error code"
|
85
|
-
},
|
86
|
-
"message": {
|
87
|
-
"type": "string",
|
88
|
-
"description": "Error message"
|
89
|
-
},
|
90
|
-
"details": {
|
91
|
-
"type": "object",
|
92
|
-
"description": "Detailed error information"
|
93
|
-
}
|
94
|
-
},
|
95
|
-
"required": ["code", "message"]
|
96
|
-
},
|
97
|
-
"id": {
|
98
|
-
"oneOf": [
|
99
|
-
{"type": "string"},
|
100
|
-
{"type": "integer"},
|
101
|
-
{"type": "null"}
|
102
|
-
],
|
103
|
-
"description": "Request ID"
|
104
|
-
}
|
105
|
-
},
|
106
|
-
"required": ["jsonrpc", "error"]
|
107
|
-
}
|
108
|
-
},
|
109
|
-
"oneOf": [
|
110
|
-
{"$ref": "#/definitions/command"},
|
111
|
-
{"$ref": "#/definitions/success_response"},
|
112
|
-
{"$ref": "#/definitions/error_response"}
|
113
|
-
]
|
114
|
-
}
|
@@ -1,314 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"openapi": "3.0.2",
|
3
|
-
"info": {
|
4
|
-
"title": "MCP Microservice API",
|
5
|
-
"description": "API для выполнения команд микросервиса",
|
6
|
-
"version": "1.0.0"
|
7
|
-
},
|
8
|
-
"paths": {
|
9
|
-
"/cmd": {
|
10
|
-
"post": {
|
11
|
-
"summary": "Execute Command",
|
12
|
-
"description": "Executes a command via JSON-RPC protocol.",
|
13
|
-
"operationId": "execute_command",
|
14
|
-
"requestBody": {
|
15
|
-
"content": {
|
16
|
-
"application/json": {
|
17
|
-
"schema": {
|
18
|
-
"oneOf": [
|
19
|
-
{ "$ref": "#/components/schemas/CommandRequest" },
|
20
|
-
{ "$ref": "#/components/schemas/JsonRpcRequest" }
|
21
|
-
]
|
22
|
-
}
|
23
|
-
}
|
24
|
-
},
|
25
|
-
"required": true
|
26
|
-
},
|
27
|
-
"responses": {
|
28
|
-
"200": {
|
29
|
-
"description": "Successful Response",
|
30
|
-
"content": {
|
31
|
-
"application/json": {
|
32
|
-
"schema": {
|
33
|
-
"oneOf": [
|
34
|
-
{ "$ref": "#/components/schemas/CommandResponse" },
|
35
|
-
{ "$ref": "#/components/schemas/JsonRpcResponse" }
|
36
|
-
]
|
37
|
-
}
|
38
|
-
}
|
39
|
-
}
|
40
|
-
},
|
41
|
-
"422": {
|
42
|
-
"description": "Validation Error",
|
43
|
-
"content": {
|
44
|
-
"application/json": {
|
45
|
-
"schema": {
|
46
|
-
"$ref": "#/components/schemas/HTTPValidationError"
|
47
|
-
}
|
48
|
-
}
|
49
|
-
}
|
50
|
-
}
|
51
|
-
}
|
52
|
-
}
|
53
|
-
},
|
54
|
-
"/health": {
|
55
|
-
"get": {
|
56
|
-
"summary": "Проверить работоспособность сервиса",
|
57
|
-
"description": "Возвращает информацию о состоянии сервиса",
|
58
|
-
"operationId": "health_check",
|
59
|
-
"responses": {
|
60
|
-
"200": {
|
61
|
-
"description": "Информация о состоянии сервиса",
|
62
|
-
"content": {
|
63
|
-
"application/json": {
|
64
|
-
"schema": {
|
65
|
-
"$ref": "#/components/schemas/HealthResponse"
|
66
|
-
}
|
67
|
-
}
|
68
|
-
}
|
69
|
-
}
|
70
|
-
}
|
71
|
-
}
|
72
|
-
},
|
73
|
-
"/openapi.json": {
|
74
|
-
"get": {
|
75
|
-
"summary": "Get Openapi Schema",
|
76
|
-
"description": "Returns OpenAPI schema.",
|
77
|
-
"operationId": "get_openapi_schema_openapi_json_get",
|
78
|
-
"responses": {
|
79
|
-
"200": {
|
80
|
-
"description": "Successful Response",
|
81
|
-
"content": {
|
82
|
-
"application/json": {
|
83
|
-
"schema": {}
|
84
|
-
}
|
85
|
-
}
|
86
|
-
}
|
87
|
-
}
|
88
|
-
}
|
89
|
-
},
|
90
|
-
"/api/commands": {
|
91
|
-
"get": {
|
92
|
-
"summary": "Get Commands",
|
93
|
-
"description": "Returns list of available commands with their descriptions.",
|
94
|
-
"operationId": "get_commands_api_commands_get",
|
95
|
-
"responses": {
|
96
|
-
"200": {
|
97
|
-
"description": "Successful Response",
|
98
|
-
"content": {
|
99
|
-
"application/json": {
|
100
|
-
"schema": {}
|
101
|
-
}
|
102
|
-
}
|
103
|
-
}
|
104
|
-
}
|
105
|
-
}
|
106
|
-
}
|
107
|
-
},
|
108
|
-
"components": {
|
109
|
-
"schemas": {
|
110
|
-
"CommandRequest": {
|
111
|
-
"title": "CommandRequest",
|
112
|
-
"description": "Запрос на выполнение команды",
|
113
|
-
"type": "object",
|
114
|
-
"required": [
|
115
|
-
"command"
|
116
|
-
],
|
117
|
-
"properties": {
|
118
|
-
"command": {
|
119
|
-
"title": "Command",
|
120
|
-
"description": "Команда для выполнения",
|
121
|
-
"type": "string"
|
122
|
-
},
|
123
|
-
"params": {
|
124
|
-
"title": "Parameters",
|
125
|
-
"description": "Параметры команды, зависят от типа команды",
|
126
|
-
"type": "object",
|
127
|
-
"additionalProperties": true
|
128
|
-
}
|
129
|
-
}
|
130
|
-
},
|
131
|
-
"CommandResponse": {
|
132
|
-
"title": "CommandResponse",
|
133
|
-
"description": "Ответ на выполнение команды",
|
134
|
-
"type": "object",
|
135
|
-
"required": [
|
136
|
-
"result"
|
137
|
-
],
|
138
|
-
"properties": {
|
139
|
-
"result": {
|
140
|
-
"title": "Result",
|
141
|
-
"description": "Результат выполнения команды"
|
142
|
-
}
|
143
|
-
}
|
144
|
-
},
|
145
|
-
"JsonRpcRequest": {
|
146
|
-
"properties": {
|
147
|
-
"jsonrpc": {
|
148
|
-
"type": "string",
|
149
|
-
"title": "Jsonrpc",
|
150
|
-
"description": "JSON-RPC version",
|
151
|
-
"default": "2.0"
|
152
|
-
},
|
153
|
-
"method": {
|
154
|
-
"type": "string",
|
155
|
-
"title": "Method",
|
156
|
-
"description": "Method name to call"
|
157
|
-
},
|
158
|
-
"params": {
|
159
|
-
"additionalProperties": true,
|
160
|
-
"type": "object",
|
161
|
-
"title": "Params",
|
162
|
-
"description": "Method parameters",
|
163
|
-
"default": {}
|
164
|
-
},
|
165
|
-
"id": {
|
166
|
-
"anyOf": [
|
167
|
-
{
|
168
|
-
"type": "string"
|
169
|
-
},
|
170
|
-
{
|
171
|
-
"type": "integer"
|
172
|
-
},
|
173
|
-
{
|
174
|
-
"type": "null"
|
175
|
-
}
|
176
|
-
],
|
177
|
-
"title": "Id",
|
178
|
-
"description": "Request identifier"
|
179
|
-
}
|
180
|
-
},
|
181
|
-
"type": "object",
|
182
|
-
"required": [
|
183
|
-
"method"
|
184
|
-
],
|
185
|
-
"title": "JsonRpcRequest",
|
186
|
-
"description": "Base model for JSON-RPC requests."
|
187
|
-
},
|
188
|
-
"JsonRpcResponse": {
|
189
|
-
"properties": {
|
190
|
-
"jsonrpc": {
|
191
|
-
"type": "string",
|
192
|
-
"title": "Jsonrpc",
|
193
|
-
"description": "JSON-RPC version",
|
194
|
-
"default": "2.0"
|
195
|
-
},
|
196
|
-
"result": {
|
197
|
-
"anyOf": [
|
198
|
-
{},
|
199
|
-
{
|
200
|
-
"type": "null"
|
201
|
-
}
|
202
|
-
],
|
203
|
-
"title": "Result",
|
204
|
-
"description": "Method execution result"
|
205
|
-
},
|
206
|
-
"error": {
|
207
|
-
"anyOf": [
|
208
|
-
{
|
209
|
-
"additionalProperties": true,
|
210
|
-
"type": "object"
|
211
|
-
},
|
212
|
-
{
|
213
|
-
"type": "null"
|
214
|
-
}
|
215
|
-
],
|
216
|
-
"title": "Error",
|
217
|
-
"description": "Error information"
|
218
|
-
},
|
219
|
-
"id": {
|
220
|
-
"anyOf": [
|
221
|
-
{
|
222
|
-
"type": "string"
|
223
|
-
},
|
224
|
-
{
|
225
|
-
"type": "integer"
|
226
|
-
},
|
227
|
-
{
|
228
|
-
"type": "null"
|
229
|
-
}
|
230
|
-
],
|
231
|
-
"title": "Id",
|
232
|
-
"description": "Request identifier"
|
233
|
-
}
|
234
|
-
},
|
235
|
-
"type": "object",
|
236
|
-
"title": "JsonRpcResponse",
|
237
|
-
"description": "Base model for JSON-RPC responses."
|
238
|
-
},
|
239
|
-
"HealthResponse": {
|
240
|
-
"title": "HealthResponse",
|
241
|
-
"description": "Информация о состоянии сервиса",
|
242
|
-
"type": "object",
|
243
|
-
"required": [
|
244
|
-
"status",
|
245
|
-
"model",
|
246
|
-
"version"
|
247
|
-
],
|
248
|
-
"properties": {
|
249
|
-
"status": {
|
250
|
-
"title": "Status",
|
251
|
-
"description": "Статус сервиса (ok/error)",
|
252
|
-
"type": "string"
|
253
|
-
},
|
254
|
-
"model": {
|
255
|
-
"title": "Model",
|
256
|
-
"description": "Текущая активная модель",
|
257
|
-
"type": "string"
|
258
|
-
},
|
259
|
-
"version": {
|
260
|
-
"title": "Version",
|
261
|
-
"description": "Версия сервиса",
|
262
|
-
"type": "string"
|
263
|
-
}
|
264
|
-
}
|
265
|
-
},
|
266
|
-
"HTTPValidationError": {
|
267
|
-
"properties": {
|
268
|
-
"detail": {
|
269
|
-
"items": {
|
270
|
-
"$ref": "#/components/schemas/ValidationError"
|
271
|
-
},
|
272
|
-
"type": "array",
|
273
|
-
"title": "Detail"
|
274
|
-
}
|
275
|
-
},
|
276
|
-
"type": "object",
|
277
|
-
"title": "HTTPValidationError"
|
278
|
-
},
|
279
|
-
"ValidationError": {
|
280
|
-
"properties": {
|
281
|
-
"loc": {
|
282
|
-
"items": {
|
283
|
-
"anyOf": [
|
284
|
-
{
|
285
|
-
"type": "string"
|
286
|
-
},
|
287
|
-
{
|
288
|
-
"type": "integer"
|
289
|
-
}
|
290
|
-
]
|
291
|
-
},
|
292
|
-
"type": "array",
|
293
|
-
"title": "Location"
|
294
|
-
},
|
295
|
-
"msg": {
|
296
|
-
"type": "string",
|
297
|
-
"title": "Message"
|
298
|
-
},
|
299
|
-
"type": {
|
300
|
-
"type": "string",
|
301
|
-
"title": "Error Type"
|
302
|
-
}
|
303
|
-
},
|
304
|
-
"type": "object",
|
305
|
-
"required": [
|
306
|
-
"loc",
|
307
|
-
"msg",
|
308
|
-
"type"
|
309
|
-
],
|
310
|
-
"title": "ValidationError"
|
311
|
-
}
|
312
|
-
}
|
313
|
-
}
|
314
|
-
}
|