HostedMcpServerTool.Headers Propriété

Définition

Obtient ou définit un dictionnaire mutable d’en-têtes HTTP à inclure lors de l’appel du serveur MCP distant.

public:
 property System::Collections::Generic::IDictionary<System::String ^, System::String ^> ^ Headers { System::Collections::Generic::IDictionary<System::String ^, System::String ^> ^ get(); void set(System::Collections::Generic::IDictionary<System::String ^, System::String ^> ^ value); };
public System.Collections.Generic.IDictionary<string,string>? Headers { get; set; }
member this.Headers : System.Collections.Generic.IDictionary<string, string> with get, set
Public Property Headers As IDictionary(Of String, String)

Valeur de propriété

Remarques

Le fournisseur sous-jacent n’est pas garanti pour prendre en charge ou respecter les en-têtes.

Cette propriété est utile pour spécifier l’en-tête d’authentification ou d’autres en-têtes requis par le serveur MCP.

Comme les noms d’en-tête HTTP ne respectent pas la casse, les appelants doivent utiliser OrdinalIgnoreCase la comparaison lors de la construction du dictionnaire.

S’applique à