MCPcopy Create free account
hub / github.com/NVIDIA/OpenShell / profile

Function profile

crates/openshell-providers/src/discovery.rs:83–123  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

81 use crate::{ProviderError, ProviderTypeProfile};
82
83 fn profile() -> ProviderTypeProfile {
84 ProviderTypeProfile {
85 id: "custom".to_string(),
86 resource_version: 0,
87 display_name: "Custom".to_string(),
88 description: String::new(),
89 category: openshell_core::proto::ProviderProfileCategory::Other,
90 credentials: vec![
91 CredentialProfile {
92 name: "api_key".to_string(),
93 env_vars: vec!["CUSTOM_API_KEY".to_string(), "CUSTOM_API_TOKEN".to_string()],
94 required: true,
95 description: String::new(),
96 auth_style: String::new(),
97 header_name: String::new(),
98 query_param: String::new(),
99 refresh: None,
100 path_template: String::new(),
101 token_grant: None,
102 },
103 CredentialProfile {
104 name: "secondary".to_string(),
105 env_vars: vec!["CUSTOM_API_KEY".to_string()],
106 required: false,
107 description: String::new(),
108 auth_style: String::new(),
109 header_name: String::new(),
110 query_param: String::new(),
111 refresh: None,
112 path_template: String::new(),
113 token_grant: None,
114 },
115 ],
116 endpoints: Vec::new(),
117 binaries: Vec::new(),
118 inference_capable: false,
119 discovery: DiscoveryProfile {
120 credentials: vec!["api_key".to_string(), "secondary".to_string()],
121 },
122 }
123 }
124
125 #[test]
126 fn profile_discovery_scans_referenced_credential_env_vars() {

Calls

no outgoing calls