mcp-proxy-adapter 4.1.0__py3-none-any.whl → 6.0.0__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/__main__.py +12 -0
- mcp_proxy_adapter/api/app.py +138 -11
- mcp_proxy_adapter/api/handlers.py +16 -1
- mcp_proxy_adapter/api/middleware/__init__.py +30 -29
- mcp_proxy_adapter/api/middleware/auth_adapter.py +235 -0
- mcp_proxy_adapter/api/middleware/error_handling.py +9 -0
- mcp_proxy_adapter/api/middleware/factory.py +219 -0
- mcp_proxy_adapter/api/middleware/logging.py +32 -6
- mcp_proxy_adapter/api/middleware/mtls_adapter.py +305 -0
- mcp_proxy_adapter/api/middleware/mtls_middleware.py +296 -0
- mcp_proxy_adapter/api/middleware/protocol_middleware.py +135 -0
- mcp_proxy_adapter/api/middleware/rate_limit_adapter.py +241 -0
- mcp_proxy_adapter/api/middleware/roles_adapter.py +365 -0
- mcp_proxy_adapter/api/middleware/roles_middleware.py +381 -0
- mcp_proxy_adapter/api/middleware/security.py +376 -0
- mcp_proxy_adapter/api/middleware/token_auth_middleware.py +261 -0
- mcp_proxy_adapter/api/middleware/transport_middleware.py +122 -0
- mcp_proxy_adapter/commands/__init__.py +13 -4
- mcp_proxy_adapter/commands/auth_validation_command.py +408 -0
- mcp_proxy_adapter/commands/base.py +61 -30
- mcp_proxy_adapter/commands/builtin_commands.py +89 -0
- mcp_proxy_adapter/commands/catalog_manager.py +838 -0
- mcp_proxy_adapter/commands/cert_monitor_command.py +620 -0
- mcp_proxy_adapter/commands/certificate_management_command.py +608 -0
- mcp_proxy_adapter/commands/command_registry.py +705 -345
- mcp_proxy_adapter/commands/dependency_manager.py +245 -0
- mcp_proxy_adapter/commands/health_command.py +7 -0
- mcp_proxy_adapter/commands/hooks.py +200 -167
- mcp_proxy_adapter/commands/key_management_command.py +506 -0
- mcp_proxy_adapter/commands/load_command.py +176 -0
- mcp_proxy_adapter/commands/plugins_command.py +235 -0
- mcp_proxy_adapter/commands/protocol_management_command.py +232 -0
- mcp_proxy_adapter/commands/proxy_registration_command.py +268 -0
- mcp_proxy_adapter/commands/reload_command.py +48 -50
- mcp_proxy_adapter/commands/result.py +1 -0
- mcp_proxy_adapter/commands/roles_management_command.py +697 -0
- mcp_proxy_adapter/commands/ssl_setup_command.py +483 -0
- mcp_proxy_adapter/commands/token_management_command.py +529 -0
- mcp_proxy_adapter/commands/transport_management_command.py +144 -0
- mcp_proxy_adapter/commands/unload_command.py +158 -0
- mcp_proxy_adapter/config.py +99 -2
- mcp_proxy_adapter/core/auth_validator.py +606 -0
- mcp_proxy_adapter/core/certificate_utils.py +827 -0
- mcp_proxy_adapter/core/config_converter.py +405 -0
- mcp_proxy_adapter/core/config_validator.py +218 -0
- mcp_proxy_adapter/core/logging.py +11 -0
- mcp_proxy_adapter/core/protocol_manager.py +226 -0
- mcp_proxy_adapter/core/proxy_registration.py +270 -0
- mcp_proxy_adapter/core/role_utils.py +426 -0
- mcp_proxy_adapter/core/security_adapter.py +373 -0
- mcp_proxy_adapter/core/security_factory.py +239 -0
- mcp_proxy_adapter/core/settings.py +1 -0
- mcp_proxy_adapter/core/ssl_utils.py +233 -0
- mcp_proxy_adapter/core/transport_manager.py +292 -0
- mcp_proxy_adapter/custom_openapi.py +22 -11
- mcp_proxy_adapter/examples/basic_server/config.json +58 -23
- mcp_proxy_adapter/examples/basic_server/config_all_protocols.json +54 -0
- mcp_proxy_adapter/examples/basic_server/config_http.json +70 -0
- mcp_proxy_adapter/examples/basic_server/config_http_only.json +52 -0
- mcp_proxy_adapter/examples/basic_server/config_https.json +58 -0
- mcp_proxy_adapter/examples/basic_server/config_mtls.json +58 -0
- mcp_proxy_adapter/examples/basic_server/config_ssl.json +46 -0
- mcp_proxy_adapter/examples/basic_server/server.py +17 -1
- mcp_proxy_adapter/examples/custom_commands/__init__.py +1 -1
- mcp_proxy_adapter/examples/custom_commands/advanced_hooks.py +339 -23
- mcp_proxy_adapter/examples/custom_commands/auto_commands/test_command.py +105 -0
- mcp_proxy_adapter/examples/custom_commands/catalog/commands/test_command.py +129 -0
- mcp_proxy_adapter/examples/custom_commands/config.json +97 -41
- mcp_proxy_adapter/examples/custom_commands/config_all_protocols.json +46 -0
- mcp_proxy_adapter/examples/custom_commands/config_https_only.json +46 -0
- mcp_proxy_adapter/examples/custom_commands/config_https_transport.json +33 -0
- mcp_proxy_adapter/examples/custom_commands/config_mtls_only.json +46 -0
- mcp_proxy_adapter/examples/custom_commands/config_mtls_transport.json +33 -0
- mcp_proxy_adapter/examples/custom_commands/config_single_transport.json +33 -0
- mcp_proxy_adapter/examples/custom_commands/full_help_response.json +1 -0
- mcp_proxy_adapter/examples/custom_commands/generated_openapi.json +629 -0
- mcp_proxy_adapter/examples/custom_commands/get_openapi.py +103 -0
- mcp_proxy_adapter/examples/custom_commands/loadable_commands/test_ignored.py +129 -0
- mcp_proxy_adapter/examples/custom_commands/proxy_connection_manager.py +278 -0
- mcp_proxy_adapter/examples/custom_commands/server.py +92 -63
- mcp_proxy_adapter/examples/custom_commands/simple_openapi_server.py +75 -0
- mcp_proxy_adapter/examples/custom_commands/start_server_with_proxy_manager.py +299 -0
- mcp_proxy_adapter/examples/custom_commands/start_server_with_registration.py +278 -0
- mcp_proxy_adapter/examples/custom_commands/test_openapi.py +27 -0
- mcp_proxy_adapter/examples/custom_commands/test_registry.py +23 -0
- mcp_proxy_adapter/examples/custom_commands/test_simple.py +19 -0
- mcp_proxy_adapter/examples/custom_project_example/README.md +103 -0
- mcp_proxy_adapter/examples/custom_project_example/README_EN.md +103 -0
- mcp_proxy_adapter/examples/simple_custom_commands/README.md +149 -0
- mcp_proxy_adapter/examples/simple_custom_commands/README_EN.md +149 -0
- mcp_proxy_adapter/main.py +175 -0
- mcp_proxy_adapter/schemas/roles_schema.json +162 -0
- mcp_proxy_adapter/tests/unit/test_config.py +53 -0
- mcp_proxy_adapter/version.py +1 -1
- {mcp_proxy_adapter-4.1.0.dist-info → mcp_proxy_adapter-6.0.0.dist-info}/METADATA +2 -1
- mcp_proxy_adapter-6.0.0.dist-info/RECORD +179 -0
- mcp_proxy_adapter/commands/reload_settings_command.py +0 -125
- mcp_proxy_adapter-4.1.0.dist-info/RECORD +0 -110
- {mcp_proxy_adapter-4.1.0.dist-info → mcp_proxy_adapter-6.0.0.dist-info}/WHEEL +0 -0
- {mcp_proxy_adapter-4.1.0.dist-info → mcp_proxy_adapter-6.0.0.dist-info}/licenses/LICENSE +0 -0
- {mcp_proxy_adapter-4.1.0.dist-info → mcp_proxy_adapter-6.0.0.dist-info}/top_level.txt +0 -0
@@ -3,14 +3,15 @@
|
|
3
3
|
"host": "0.0.0.0",
|
4
4
|
"port": 8000,
|
5
5
|
"debug": true,
|
6
|
-
"log_level": "
|
6
|
+
"log_level": "INFO"
|
7
7
|
},
|
8
8
|
"logging": {
|
9
|
-
"level": "
|
10
|
-
"
|
11
|
-
"
|
12
|
-
"
|
13
|
-
"
|
9
|
+
"level": "INFO",
|
10
|
+
"file": null,
|
11
|
+
"log_dir": "./logs",
|
12
|
+
"log_file": "mcp_proxy_adapter.log",
|
13
|
+
"error_log_file": "mcp_proxy_adapter_error.log",
|
14
|
+
"access_log_file": "mcp_proxy_adapter_access.log",
|
14
15
|
"max_file_size": "10MB",
|
15
16
|
"backup_count": 5,
|
16
17
|
"format": "%(asctime)s - %(name)s - %(levelname)s - %(message)s",
|
@@ -20,43 +21,98 @@
|
|
20
21
|
},
|
21
22
|
"commands": {
|
22
23
|
"auto_discovery": true,
|
23
|
-
"
|
24
|
-
"
|
25
|
-
"
|
24
|
+
"commands_directory": "./commands",
|
25
|
+
"catalog_directory": "./catalog",
|
26
|
+
"plugin_servers": [],
|
27
|
+
"auto_install_dependencies": true,
|
28
|
+
"discovery_path": "mcp_proxy_adapter.commands"
|
26
29
|
},
|
27
|
-
"
|
28
|
-
"
|
29
|
-
"
|
30
|
-
"
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
30
|
+
"ssl": {
|
31
|
+
"enabled": false,
|
32
|
+
"mode": "http_only",
|
33
|
+
"cert_file": null,
|
34
|
+
"key_file": null,
|
35
|
+
"ca_cert": null,
|
36
|
+
"verify_client": false,
|
37
|
+
"client_cert_required": false,
|
38
|
+
"cipher_suites": [
|
39
|
+
"TLS_AES_256_GCM_SHA384",
|
40
|
+
"TLS_CHACHA20_POLY1305_SHA256"
|
41
|
+
],
|
42
|
+
"min_tls_version": "1.2",
|
43
|
+
"max_tls_version": "1.3",
|
44
|
+
"token_auth": {
|
45
|
+
"enabled": false,
|
46
|
+
"header_name": "Authorization",
|
47
|
+
"token_prefix": "Bearer",
|
48
|
+
"tokens_file": "tokens.json",
|
49
|
+
"token_expiry": 3600,
|
50
|
+
"jwt_secret": "",
|
51
|
+
"jwt_algorithm": "HS256"
|
52
|
+
}
|
53
|
+
},
|
54
|
+
"roles": {
|
55
|
+
"enabled": false,
|
56
|
+
"config_file": "schemas/roles_schema.json",
|
57
|
+
"default_policy": {
|
58
|
+
"deny_by_default": true,
|
59
|
+
"require_role_match": true,
|
60
|
+
"case_sensitive": false,
|
61
|
+
"allow_wildcard": true
|
36
62
|
},
|
37
|
-
"
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
63
|
+
"auto_load": true,
|
64
|
+
"validation_enabled": true
|
65
|
+
},
|
66
|
+
"transport": {
|
67
|
+
"type": "http",
|
68
|
+
"port": null,
|
69
|
+
"ssl": {
|
70
|
+
"enabled": false,
|
71
|
+
"cert_file": null,
|
72
|
+
"key_file": null,
|
73
|
+
"ca_cert": null,
|
74
|
+
"verify_client": false,
|
75
|
+
"client_cert_required": false
|
76
|
+
}
|
77
|
+
},
|
78
|
+
"proxy_registration": {
|
79
|
+
"enabled": true,
|
80
|
+
"proxy_url": "http://localhost:3004",
|
81
|
+
"server_id": "mcp_proxy_adapter_custom",
|
82
|
+
"server_name": "Custom Commands MCP Proxy Adapter Server",
|
83
|
+
"description": "JSON-RPC API for custom commands example",
|
84
|
+
"registration_timeout": 30,
|
85
|
+
"retry_attempts": 3,
|
86
|
+
"retry_delay": 5,
|
87
|
+
"auto_register_on_startup": false,
|
88
|
+
"auto_unregister_on_shutdown": true
|
89
|
+
},
|
90
|
+
"debug": {
|
91
|
+
"enabled": false,
|
92
|
+
"level": "WARNING"
|
93
|
+
},
|
94
|
+
"protocols": {
|
95
|
+
"enabled": false,
|
96
|
+
"allowed_protocols": [
|
97
|
+
"http"
|
98
|
+
],
|
99
|
+
"http": {
|
100
|
+
"enabled": true,
|
101
|
+
"port": 8000
|
102
|
+
},
|
103
|
+
"https": {
|
104
|
+
"enabled": false,
|
105
|
+
"port": 8443
|
46
106
|
},
|
47
|
-
"
|
48
|
-
"
|
49
|
-
|
50
|
-
"description": "Manually registered echo command"
|
51
|
-
},
|
52
|
-
"data_transform": {
|
53
|
-
"enabled": true,
|
54
|
-
"description": "Data transformation command"
|
55
|
-
},
|
56
|
-
"intercept": {
|
57
|
-
"enabled": true,
|
58
|
-
"description": "Command interception example"
|
59
|
-
}
|
107
|
+
"mtls": {
|
108
|
+
"enabled": false,
|
109
|
+
"port": 9443
|
60
110
|
}
|
111
|
+
},
|
112
|
+
"auth_enabled": false,
|
113
|
+
"rate_limit_enabled": false,
|
114
|
+
"custom": {
|
115
|
+
"description": "HTTP transport server example",
|
116
|
+
"server_name": "HTTP Transport MCP Proxy Adapter Server"
|
61
117
|
}
|
62
|
-
}
|
118
|
+
}
|
@@ -0,0 +1,46 @@
|
|
1
|
+
{
|
2
|
+
"server": {
|
3
|
+
"host": "0.0.0.0",
|
4
|
+
"port": 8000,
|
5
|
+
"debug": true,
|
6
|
+
"log_level": "INFO"
|
7
|
+
},
|
8
|
+
"logging": {
|
9
|
+
"level": "INFO",
|
10
|
+
"log_dir": "./logs",
|
11
|
+
"console_output": true
|
12
|
+
},
|
13
|
+
"commands": {
|
14
|
+
"auto_discovery": true,
|
15
|
+
"discovery_path": "mcp_proxy_adapter.commands"
|
16
|
+
},
|
17
|
+
"ssl": {
|
18
|
+
"enabled": true,
|
19
|
+
"mode": "mtls",
|
20
|
+
"cert_file": "../../../test_env/server/server.crt",
|
21
|
+
"key_file": "../../../test_env/server/server.key",
|
22
|
+
"ca_cert": "../../../test_env/ca/ca.crt",
|
23
|
+
"verify_client": true,
|
24
|
+
"client_cert_required": true
|
25
|
+
},
|
26
|
+
"protocols": {
|
27
|
+
"enabled": true,
|
28
|
+
"allowed_protocols": ["http", "https", "mtls"],
|
29
|
+
"http": {
|
30
|
+
"enabled": true,
|
31
|
+
"port": 8000
|
32
|
+
},
|
33
|
+
"https": {
|
34
|
+
"enabled": true,
|
35
|
+
"port": 8443
|
36
|
+
},
|
37
|
+
"mtls": {
|
38
|
+
"enabled": true,
|
39
|
+
"port": 9443
|
40
|
+
}
|
41
|
+
},
|
42
|
+
"custom": {
|
43
|
+
"description": "Advanced server with all protocols support",
|
44
|
+
"server_name": "Advanced MCP Proxy Adapter Server"
|
45
|
+
}
|
46
|
+
}
|
@@ -0,0 +1,46 @@
|
|
1
|
+
{
|
2
|
+
"server": {
|
3
|
+
"host": "0.0.0.0",
|
4
|
+
"port": 8443,
|
5
|
+
"debug": true,
|
6
|
+
"log_level": "INFO"
|
7
|
+
},
|
8
|
+
"logging": {
|
9
|
+
"level": "INFO",
|
10
|
+
"log_dir": "./logs",
|
11
|
+
"console_output": true
|
12
|
+
},
|
13
|
+
"commands": {
|
14
|
+
"auto_discovery": true,
|
15
|
+
"discovery_path": "mcp_proxy_adapter.commands"
|
16
|
+
},
|
17
|
+
"ssl": {
|
18
|
+
"enabled": true,
|
19
|
+
"mode": "https_only",
|
20
|
+
"cert_file": "../../../test_env/server/server.crt",
|
21
|
+
"key_file": "../../../test_env/server/server.key",
|
22
|
+
"ca_cert": "../../../test_env/ca/ca.crt",
|
23
|
+
"verify_client": false,
|
24
|
+
"client_cert_required": false
|
25
|
+
},
|
26
|
+
"protocols": {
|
27
|
+
"enabled": true,
|
28
|
+
"allowed_protocols": ["https"],
|
29
|
+
"http": {
|
30
|
+
"enabled": false,
|
31
|
+
"port": 8000
|
32
|
+
},
|
33
|
+
"https": {
|
34
|
+
"enabled": true,
|
35
|
+
"port": 8443
|
36
|
+
},
|
37
|
+
"mtls": {
|
38
|
+
"enabled": false,
|
39
|
+
"port": 9443
|
40
|
+
}
|
41
|
+
},
|
42
|
+
"custom": {
|
43
|
+
"description": "HTTPS-only server example",
|
44
|
+
"server_name": "HTTPS MCP Proxy Adapter Server"
|
45
|
+
}
|
46
|
+
}
|
@@ -0,0 +1,33 @@
|
|
1
|
+
{
|
2
|
+
"server": {
|
3
|
+
"host": "0.0.0.0",
|
4
|
+
"port": 8443,
|
5
|
+
"debug": true,
|
6
|
+
"log_level": "INFO"
|
7
|
+
},
|
8
|
+
"logging": {
|
9
|
+
"level": "INFO",
|
10
|
+
"log_dir": "./logs",
|
11
|
+
"console_output": true
|
12
|
+
},
|
13
|
+
"commands": {
|
14
|
+
"auto_discovery": true,
|
15
|
+
"discovery_path": "mcp_proxy_adapter.commands"
|
16
|
+
},
|
17
|
+
"transport": {
|
18
|
+
"type": "https",
|
19
|
+
"port": null,
|
20
|
+
"ssl": {
|
21
|
+
"enabled": true,
|
22
|
+
"cert_file": "../../../test_env/server/server.crt",
|
23
|
+
"key_file": "../../../test_env/server/server.key",
|
24
|
+
"ca_cert": "../../../test_env/ca/ca.crt",
|
25
|
+
"verify_client": false,
|
26
|
+
"client_cert_required": false
|
27
|
+
}
|
28
|
+
},
|
29
|
+
"custom": {
|
30
|
+
"description": "HTTPS transport server example",
|
31
|
+
"server_name": "HTTPS Transport MCP Proxy Adapter Server"
|
32
|
+
}
|
33
|
+
}
|
@@ -0,0 +1,46 @@
|
|
1
|
+
{
|
2
|
+
"server": {
|
3
|
+
"host": "0.0.0.0",
|
4
|
+
"port": 9443,
|
5
|
+
"debug": true,
|
6
|
+
"log_level": "INFO"
|
7
|
+
},
|
8
|
+
"logging": {
|
9
|
+
"level": "INFO",
|
10
|
+
"log_dir": "./logs",
|
11
|
+
"console_output": true
|
12
|
+
},
|
13
|
+
"commands": {
|
14
|
+
"auto_discovery": true,
|
15
|
+
"discovery_path": "mcp_proxy_adapter.commands"
|
16
|
+
},
|
17
|
+
"ssl": {
|
18
|
+
"enabled": true,
|
19
|
+
"mode": "mtls",
|
20
|
+
"cert_file": "../../../test_env/server/server.crt",
|
21
|
+
"key_file": "../../../test_env/server/server.key",
|
22
|
+
"ca_cert": "../../../test_env/ca/ca.crt",
|
23
|
+
"verify_client": true,
|
24
|
+
"client_cert_required": true
|
25
|
+
},
|
26
|
+
"protocols": {
|
27
|
+
"enabled": true,
|
28
|
+
"allowed_protocols": ["mtls"],
|
29
|
+
"http": {
|
30
|
+
"enabled": false,
|
31
|
+
"port": 8000
|
32
|
+
},
|
33
|
+
"https": {
|
34
|
+
"enabled": false,
|
35
|
+
"port": 8443
|
36
|
+
},
|
37
|
+
"mtls": {
|
38
|
+
"enabled": true,
|
39
|
+
"port": 9443
|
40
|
+
}
|
41
|
+
},
|
42
|
+
"custom": {
|
43
|
+
"description": "MTLS-only server example",
|
44
|
+
"server_name": "MTLS MCP Proxy Adapter Server"
|
45
|
+
}
|
46
|
+
}
|
@@ -0,0 +1,33 @@
|
|
1
|
+
{
|
2
|
+
"server": {
|
3
|
+
"host": "0.0.0.0",
|
4
|
+
"port": 9443,
|
5
|
+
"debug": true,
|
6
|
+
"log_level": "INFO"
|
7
|
+
},
|
8
|
+
"logging": {
|
9
|
+
"level": "INFO",
|
10
|
+
"log_dir": "./logs",
|
11
|
+
"console_output": true
|
12
|
+
},
|
13
|
+
"commands": {
|
14
|
+
"auto_discovery": true,
|
15
|
+
"discovery_path": "mcp_proxy_adapter.commands"
|
16
|
+
},
|
17
|
+
"transport": {
|
18
|
+
"type": "mtls",
|
19
|
+
"port": null,
|
20
|
+
"ssl": {
|
21
|
+
"enabled": true,
|
22
|
+
"cert_file": "../../../test_env/server/server.crt",
|
23
|
+
"key_file": "../../../test_env/server/server.key",
|
24
|
+
"ca_cert": "../../../test_env/ca/ca.crt",
|
25
|
+
"verify_client": true,
|
26
|
+
"client_cert_required": true
|
27
|
+
}
|
28
|
+
},
|
29
|
+
"custom": {
|
30
|
+
"description": "MTLS transport server example",
|
31
|
+
"server_name": "MTLS Transport MCP Proxy Adapter Server"
|
32
|
+
}
|
33
|
+
}
|
@@ -0,0 +1,33 @@
|
|
1
|
+
{
|
2
|
+
"server": {
|
3
|
+
"host": "0.0.0.0",
|
4
|
+
"port": 8000,
|
5
|
+
"debug": true,
|
6
|
+
"log_level": "INFO"
|
7
|
+
},
|
8
|
+
"logging": {
|
9
|
+
"level": "INFO",
|
10
|
+
"log_dir": "./logs",
|
11
|
+
"console_output": true
|
12
|
+
},
|
13
|
+
"commands": {
|
14
|
+
"auto_discovery": true,
|
15
|
+
"discovery_path": "mcp_proxy_adapter.commands"
|
16
|
+
},
|
17
|
+
"transport": {
|
18
|
+
"type": "http",
|
19
|
+
"port": null,
|
20
|
+
"ssl": {
|
21
|
+
"enabled": false,
|
22
|
+
"cert_file": null,
|
23
|
+
"key_file": null,
|
24
|
+
"ca_cert": null,
|
25
|
+
"verify_client": false,
|
26
|
+
"client_cert_required": false
|
27
|
+
}
|
28
|
+
},
|
29
|
+
"custom": {
|
30
|
+
"description": "Single transport server example",
|
31
|
+
"server_name": "Single Transport MCP Proxy Adapter Server"
|
32
|
+
}
|
33
|
+
}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"jsonrpc":"2.0","result":{"commands":{"echo":{"name":"echo","metadata":{"name":"echo","version":"0.1","plugin":"","descr":"","category":"","author":"","email":"","source_url":"","summary":"Echo command that returns the input message.","description":"Echo command that returns the input message.","params":{"message":{"name":"message","required":false,"type":"typing.Optional[str]","default":null},"kwargs":{"name":"kwargs","required":true}},"examples":[{"command":"echo","params":{"kwargs":"..."},"description":"Call echo command with required parameters"},{"command":"echo","params":{"message":null,"kwargs":"..."},"description":"Call echo command with all parameters"}],"schema":{"type":"object","properties":{"message":{"type":"string","description":"Message to echo","default":"Hello, World!"},"text":{"type":"string","description":"Alternative parameter name for message"}}},"result_schema":{"type":"object","properties":{"data":{"type":"object","properties":{"message":{"type":"string"},"timestamp":{"type":"string"},"echoed":{"type":"boolean"}},"required":["message","timestamp","echoed"]}},"required":["data"]},"result_class":"EchoResult"},"schema":{"type":"object","properties":{"message":{"type":"string","description":"Message to echo","default":"Hello, World!"},"text":{"type":"string","description":"Alternative parameter name for message"}}},"type":"custom"},"help":{"name":"help","metadata":{"name":"help","version":"0.1","plugin":"","descr":"","category":"","author":"","email":"","source_url":"","summary":"Custom help command with enhanced functionality.","description":"Custom help command with enhanced functionality.","params":{"cmdname":{"name":"cmdname","required":false,"type":"typing.Optional[str]","default":null},"kwargs":{"name":"kwargs","required":true}},"examples":[{"command":"help","params":{"kwargs":"..."},"description":"Call help command with required parameters"},{"command":"help","params":{"cmdname":null,"kwargs":"..."},"description":"Call help command with all parameters"}],"schema":{"type":"object","properties":{"cmdname":{"type":"string","description":"Name of specific command to get help for"}}},"result_schema":{"type":"object","properties":{"cmdname":{"type":"string","description":"Name of the command"},"info":{"type":"object","properties":{"description":{"type":"string"},"summary":{"type":"string"},"params":{"type":"object"},"examples":{"type":"array"},"custom_help":{"type":"boolean"}}},"tool_info":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string"},"version":{"type":"string"},"custom_help":{"type":"boolean"}}},"help_usage":{"type":"object","properties":{"description":{"type":"string"},"examples":{"type":"array"}}},"commands":{"type":"object"},"total":{"type":"integer"},"custom_features":{"type":"object"}}},"result_class":"CustomHelpResult"},"schema":{"type":"object","properties":{"cmdname":{"type":"string","description":"Name of specific command to get help for"}}},"type":"custom"},"health":{"name":"health","metadata":{"name":"health","version":"0.1","plugin":"","descr":"","category":"","author":"","email":"","source_url":"","summary":"Custom health command with enhanced system information.","description":"Custom health command with enhanced system information.","params":{"kwargs":{"name":"kwargs","required":true}},"examples":[{"command":"health","params":{"kwargs":"..."},"description":"Call health command with required parameters"}],"schema":{"type":"object","properties":{},"description":"Get enhanced system health information"},"result_schema":{"type":"object","properties":{"data":{"type":"object","properties":{"status":{"type":"string"},"version":{"type":"string"},"uptime":{"type":"number"},"components":{"type":"object"},"custom_metrics":{"type":"object"},"custom_health":{"type":"boolean"}},"required":["status","version","uptime","components","custom_metrics","custom_health"]}},"required":["data"]},"result_class":"CustomHealthResult"},"schema":{"type":"object","properties":{},"description":"Get enhanced system health information"},"type":"custom"},"data_transform":{"name":"data_transform","metadata":{"name":"data_transform","version":"0.1","plugin":"","descr":"","category":"","author":"","email":"","source_url":"","summary":"Data transform command for demonstrating advanced hooks.","description":"Data transform command for demonstrating advanced hooks.","params":{"data":{"name":"data","required":false,"type":"typing.Optional[typing.Dict[str, typing.Any]]","default":null},"transform_type":{"name":"transform_type","required":false,"type":"typing.Optional[str]","default":null},"kwargs":{"name":"kwargs","required":true}},"examples":[{"command":"data_transform","params":{"kwargs":"..."},"description":"Call data_transform command with required parameters"},{"command":"data_transform","params":{"data":null,"transform_type":null,"kwargs":"..."},"description":"Call data_transform command with all parameters"}],"schema":{"type":"object","properties":{"data":{"type":"object","description":"Input data to transform"},"transform_type":{"type":"string","enum":["uppercase","lowercase","reverse","default"],"description":"Type of transformation to apply"}}},"result_schema":{"type":"object","properties":{"original_data":{"type":"object"},"transformed_data":{"type":"object"},"processing_info":{"type":"object"},"command_type":{"type":"string"}}},"result_class":"DataTransformResult"},"schema":{"type":"object","properties":{"data":{"type":"object","description":"Input data to transform"},"transform_type":{"type":"string","enum":["uppercase","lowercase","reverse","default"],"description":"Type of transformation to apply"}}},"type":"custom"},"intercept":{"name":"intercept","metadata":{"name":"intercept","version":"0.1","plugin":"","descr":"","category":"","author":"","email":"","source_url":"","summary":"Intercept command for demonstrating hook interception.","description":"Intercept command for demonstrating hook interception.","params":{"action":{"name":"action","required":false,"type":"typing.Optional[str]","default":null},"bypass_flag":{"name":"bypass_flag","required":false,"type":"typing.Optional[int]","default":null},"kwargs":{"name":"kwargs","required":true}},"examples":[{"command":"intercept","params":{"kwargs":"..."},"description":"Call intercept command with required parameters"},{"command":"intercept","params":{"action":null,"bypass_flag":null,"kwargs":"..."},"description":"Call intercept command with all parameters"}],"schema":{"type":"object","properties":{"action":{"type":"string","description":"Action to perform"},"bypass_flag":{"type":"integer","enum":[0,1],"description":"Flag to determine execution (0 = bypass, 1 = execute)"}}},"result_schema":{"type":"object","properties":{"message":{"type":"string"},"executed":{"type":"boolean"},"intercept_reason":{"type":"string"},"hook_data":{"type":"object"},"command_type":{"type":"string"}}},"result_class":"InterceptResult"},"schema":{"type":"object","properties":{"action":{"type":"string","description":"Action to perform"},"bypass_flag":{"type":"integer","enum":[0,1],"description":"Flag to determine execution (0 = bypass, 1 = execute)"}}},"type":"custom"},"manual_echo":{"name":"manual_echo","metadata":{"name":"manual_echo","version":"0.1","plugin":"","descr":"","category":"","author":"","email":"","source_url":"","summary":"Manually registered echo command.","description":"Manually registered echo command.","params":{"message":{"name":"message","required":false,"type":"typing.Optional[str]","default":null},"kwargs":{"name":"kwargs","required":true}},"examples":[{"command":"manual_echo","params":{"kwargs":"..."},"description":"Call manual_echo command with required parameters"},{"command":"manual_echo","params":{"message":null,"kwargs":"..."},"description":"Call manual_echo command with all parameters"}],"schema":{"type":"object","properties":{"message":{"type":"string","description":"Message to echo","default":"Hello from manually registered command!"}}},"result_schema":{"type":"object","properties":{"message":{"type":"string"},"manually_registered":{"type":"boolean"},"command_type":{"type":"string"}}},"result_class":"ManualEchoResult"},"schema":{"type":"object","properties":{"message":{"type":"string","description":"Message to echo","default":"Hello from manually registered command!"}}},"type":"custom"},"config":{"name":"config","metadata":{"name":"config","version":"0.1","plugin":"","descr":"","category":"","author":"","email":"","source_url":"","summary":"Command for managing service configuration.","description":"Command for managing service configuration.","params":{"operation":{"name":"operation","required":false,"type":"<class 'str'>","default":"get"},"path":{"name":"path","required":false,"type":"<class 'str'>","default":null},"value":{"name":"value","required":false,"type":"typing.Any","default":null}},"examples":[{"command":"config","description":"Call config command without parameters"},{"command":"config","params":{"operation":"get","path":null,"value":null},"description":"Call config command with all parameters"}],"schema":{"type":"object","properties":{"operation":{"type":"string","enum":["get","set"],"default":"get","description":"Operation to perform (get or set)"},"path":{"type":"string","description":"Configuration path in dot notation (e.g. 'server.host')"},"value":{"description":"Value to set (required for 'set' operation)"}},"required":["operation"],"additionalProperties":false},"result_schema":{"type":"object","properties":{"success":{"type":"boolean"},"data":{"type":"object"},"message":{"type":"string"}},"required":["success"]},"result_class":"ConfigResult"},"schema":{"type":"object","properties":{"operation":{"type":"string","enum":["get","set"],"default":"get","description":"Operation to perform (get or set)"},"path":{"type":"string","description":"Configuration path in dot notation (e.g. 'server.host')"},"value":{"description":"Value to set (required for 'set' operation)"}},"required":["operation"],"additionalProperties":false},"type":"built-in"},"reload":{"name":"reload","metadata":{"name":"reload","version":"0.1","plugin":"","descr":"","category":"","author":"","email":"","source_url":"","summary":"Command for reloading configuration and rediscovering commands.","description":"Command for reloading configuration and rediscovering commands.\nUses the unified initialization logic.","params":{"params":{"name":"params","required":true}},"examples":[{"command":"reload","params":{"params":"..."},"description":"Call reload command with required parameters"}],"schema":{"type":"object","properties":{"config_path":{"type":"string","description":"Path to configuration file to reload","default":null}},"additionalProperties":false},"result_schema":{},"result_class":null},"schema":{"type":"object","properties":{"config_path":{"type":"string","description":"Path to configuration file to reload","default":null}},"additionalProperties":false},"type":"built-in"},"settings":{"name":"settings","metadata":{"name":"settings","version":"0.1","plugin":"","descr":"","category":"","author":"","email":"","source_url":"","summary":"Command for managing framework settings.","description":"Command for managing framework settings.","params":{"params":{"name":"params","required":true}},"examples":[{"command":"settings","params":{"params":"..."},"description":"Call settings command with required parameters"}],"schema":{"type":"object","properties":{"operation":{"type":"string","description":"Operation to perform","enum":["get","set","get_all","reload"],"default":"get_all"},"key":{"type":"string","description":"Configuration key in dot notation (e.g., 'server.host', 'custom.feature_enabled')"},"value":{"description":"Configuration value to set (for 'set' operation)"}},"required":["operation"],"additionalProperties":false},"result_schema":{},"result_class":null},"schema":{"type":"object","properties":{"operation":{"type":"string","description":"Operation to perform","enum":["get","set","get_all","reload"],"default":"get_all"},"key":{"type":"string","description":"Configuration key in dot notation (e.g., 'server.host', 'custom.feature_enabled')"},"value":{"description":"Configuration value to set (for 'set' operation)"}},"required":["operation"],"additionalProperties":false},"type":"built-in"},"load":{"name":"load","metadata":{"name":"load","version":"0.1","plugin":"","descr":"","category":"","author":"","email":"","source_url":"","summary":"Command that loads commands from local path or URL.","description":"Command that loads commands from local path or URL.\n\nThis command allows dynamic loading of command modules from either local file system\nor remote HTTP/HTTPS URLs. The command automatically detects whether the source\nis a local path or URL and handles the loading accordingly.\n\nFor local paths, the command loads Python modules ending with '_command.py'.\nFor URLs, the command downloads the Python code and loads it as a temporary module.\n\nThe loaded commands are registered in the command registry and become immediately\navailable for execution. Only commands that inherit from the base Command class\nand are properly structured will be loaded and registered.\n\nSecurity considerations:\n- Local paths are validated for existence and proper naming\n- URLs are downloaded with timeout protection\n- Temporary files are automatically cleaned up after loading\n- Only files ending with '_command.py' are accepted\n\nExamples:\n- Load from local file: \"./my_command.py\"\n- Load from URL: \"https://example.com/remote_command.py\"","params":{"source":{"name":"source","required":true,"type":"<class 'str'>"},"kwargs":{"name":"kwargs","required":true}},"examples":[{"command":"load","params":{"source":"./custom_command.py"},"description":"Load a command from local file system"},{"command":"load","params":{"source":"https://raw.githubusercontent.com/user/repo/main/remote_command.py"},"description":"Load a command from GitHub raw content"},{"command":"load","params":{"source":"https://example.com/api/commands/test_command.py"},"description":"Load a command from remote API endpoint"}],"schema":{"type":"object","properties":{"source":{"type":"string","description":"Source path or URL to load command from (must end with '_command.py')","examples":["./my_command.py","https://example.com/remote_command.py"]}},"required":["source"]},"result_schema":{"type":"object","properties":{"data":{"type":"object","properties":{"success":{"type":"boolean"},"commands_loaded":{"type":"integer"},"loaded_commands":{"type":"array","items":{"type":"string"}},"source":{"type":"string"},"error":{"type":"string"}},"required":["success","commands_loaded","loaded_commands","source"]}},"required":["data"]},"result_class":"LoadResult"},"schema":{"type":"object","properties":{"source":{"type":"string","description":"Source path or URL to load command from (must end with '_command.py')","examples":["./my_command.py","https://example.com/remote_command.py"]}},"required":["source"]},"type":"built-in"},"unload":{"name":"unload","metadata":{"name":"unload","version":"0.1","plugin":"","descr":"","category":"","author":"","email":"","source_url":"","summary":"Command that unloads loaded commands from registry.","description":"Command that unloads loaded commands from registry.\n\nThis command allows removal of dynamically loaded commands from the command registry.\nOnly commands that were loaded via the 'load' command or from the commands directory\ncan be unloaded. Built-in commands and custom commands registered with higher priority\ncannot be unloaded using this command.\n\nWhen a command is unloaded:\n- The command class is removed from the loaded commands registry\n- Any command instances are also removed\n- The command becomes unavailable for execution\n- Built-in and custom commands with the same name remain unaffected\n\nThis is useful for:\n- Removing outdated or problematic commands\n- Managing memory usage by unloading unused commands\n- Testing different versions of commands\n- Cleaning up temporary commands loaded for testing\n\nNote: Unloading a command does not affect other commands and does not require\na system restart. The command can be reloaded later if needed.","params":{"command_name":{"name":"command_name","required":true,"type":"<class 'str'>"},"kwargs":{"name":"kwargs","required":true}},"examples":[{"command":"unload","params":{"command_name":"test_command"},"description":"Unload a previously loaded test command"},{"command":"unload","params":{"command_name":"remote_command"},"description":"Unload a command that was loaded from URL"},{"command":"unload","params":{"command_name":"custom_command"},"description":"Unload a custom command loaded from local file"}],"schema":{"type":"object","properties":{"command_name":{"type":"string","description":"Name of the command to unload (must be a loaded command)"}},"required":["command_name"]},"result_schema":{"type":"object","properties":{"data":{"type":"object","properties":{"success":{"type":"boolean"},"command_name":{"type":"string"},"error":{"type":"string"}},"required":["success","command_name"]}},"required":["data"]},"result_class":"UnloadResult"},"schema":{"type":"object","properties":{"command_name":{"type":"string","description":"Name of the command to unload (must be a loaded command)"}},"required":["command_name"]},"type":"built-in"},"plugins":{"name":"plugins","metadata":{"name":"plugins","summary":"Command that reads and displays available plugins from a plugins server","description":"\n Command that reads and displays available plugins from a plugins server.\n \n This command fetches a JSON file from a configured plugins server URL that contains\n a list of available plugins. Each plugin in the list typically contains metadata\n such as name, description, URL, version, and author information.\n \n The plugins server URL is configured in the system configuration under\n 'commands.plugins_server'. The JSON file should contain an array of plugin objects\n with the following structure:\n \n {\n \"plugins\": [\n {\n \"name\": \"plugin_name\",\n \"description\": \"Plugin description\",\n \"url\": \"https://server.com/plugin.py\",\n \"version\": \"1.0.0\",\n \"author\": \"Author Name\"\n }\n ]\n }\n \n This command is useful for:\n - Discovering available plugins without manually browsing the server\n - Getting metadata about plugins before loading them\n - Building plugin management interfaces\n - Checking plugin availability and versions\n \n The command will return the list of all available plugins along with their\n metadata, making it easy to choose which plugins to load.\n ","parameters":{},"examples":[{"command":"plugins","description":"Get list of available plugins from configured server"},{"command":"plugins","description":"Discover plugins without parameters"},{"command":"plugins","description":"Check plugin availability and metadata"}],"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"success":{"type":"boolean"},"plugins_server":{"type":"string"},"plugins":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string"},"url":{"type":"string"},"version":{"type":"string"},"author":{"type":"string"}}}},"total_plugins":{"type":"integer"},"error":{"type":"string"}},"required":["success","plugins_server","plugins","total_plugins"]}},"required":["data"]}},"schema":{"type":"object","properties":{},"additionalProperties":false},"type":"built-in"},"transport_management":{"name":"transport_management","metadata":{"name":"transport_management","version":"0.1","plugin":"","descr":"Manage and query transport configurations (HTTP, HTTPS, MTLS)","category":"","author":"","email":"","source_url":"","summary":"Transport management command.","description":"Transport management command.\n\nThis command provides functionality to manage and query transport configurations.","params":{"params":{"name":"params","required":true}},"examples":[{"command":"transport_management","params":{"params":"..."},"description":"Call transport_management command with required parameters"}],"schema":{"type":"object","properties":{"action":{"type":"string","enum":["get_info","validate","reload"],"description":"Action to perform"}},"required":["action"]},"result_schema":{},"result_class":null},"schema":{"type":"object","properties":{"action":{"type":"string","enum":["get_info","validate","reload"],"description":"Action to perform"}},"required":["action"]},"type":"built-in"},"proxy_registration":{"name":"proxy_registration","error":"ProxyRegistrationCommand.get_schema() missing 1 required positional argument: 'self'","type":"built-in"}},"total":14,"custom_help":true,"custom_features":{"enhanced":true,"total_commands":14,"custom_commands":["echo","help","health"],"request_id":null,"hook_processed":false}},"id":15}
|