@@ -3,6 +3,13 @@ use std::collections::HashMap;
33use schemars:: JsonSchema ;
44use serde:: { Deserialize , Serialize } ;
55
6+ pub type DownstreamBackendName = String ;
7+ pub type DownstreamToolName = String ;
8+ pub type DownstreamResourceName = String ;
9+ pub type DownstreamResourceTemplateName = String ;
10+ pub type DownstreamPromptName = String ;
11+ pub type VirtualHostId = String ;
12+
613#[ derive( Debug , Clone , Deserialize , Serialize , JsonSchema , Default ) ]
714pub enum IntegrationType {
815 #[ serde( rename = "REST" ) ]
@@ -37,12 +44,6 @@ pub struct ServiceRoute {
3744 pub upstream_name : String ,
3845}
3946
40- pub type DownstreamBackendName = String ;
41- pub type DownstreamToolName = String ;
42- pub type DownstreamResourceName = String ;
43- pub type DownstreamResourceTemplateName = String ;
44- pub type DownstreamPromptName = String ;
45-
4647#[ derive( Debug , Clone , Deserialize , Serialize , JsonSchema ) ]
4748pub struct VirtualHost {
4849 pub backends : HashMap < DownstreamBackendName , BackendMCPGateway > ,
@@ -58,5 +59,5 @@ pub struct VirtualHost {
5859
5960#[ derive( Debug , Clone , Deserialize , Serialize , JsonSchema ) ]
6061pub struct UserConfig {
61- pub virtual_hosts : HashMap < String , VirtualHost > ,
62+ pub virtual_hosts : HashMap < VirtualHostId , VirtualHost > ,
6263}
0 commit comments