Skip to content

Commit d511312

Browse files
committed
Cleanup for consistency
1 parent 531370a commit d511312

File tree

2 files changed

+1
-71
lines changed

2 files changed

+1
-71
lines changed

samples/ProtectedMCPClient/Program.cs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ static async Task Main(string[] args)
2222

2323
var authHandler = new AuthorizationDelegatingHandler(tokenProvider, "Bearer")
2424
{
25-
// 3. Set the inner handler (the handler that actually sends the request)
2625
InnerHandler = new HttpClientHandler()
2726
};
2827

@@ -39,7 +38,6 @@ static async Task Main(string[] args)
3938
Name = "Secure Weather Client"
4039
};
4140

42-
// Use the single, pre-configured HttpClient
4341
var transport = new SseClientTransport(transportOptions, httpClient);
4442

4543
var client = await McpClientFactory.CreateAsync(transport);
@@ -57,13 +55,12 @@ static async Task Main(string[] args)
5755
if (tools.Any(t => t.Name == "GetAlerts"))
5856
{
5957
Console.WriteLine("Calling GetAlerts tool...");
60-
// Update the dictionary to match the expected type IReadOnlyDictionary<string, object?>?
58+
6159
var result = await client.CallToolAsync(
6260
"GetAlerts",
6361
new Dictionary<string, object?> { { "state", "WA" } }
6462
);
6563

66-
//var result = await client.CallToolAsync("GetAuthorizationInfo");
6764
Console.WriteLine("Result: " + result.Content[0].Text);
6865
Console.WriteLine();
6966
}

src/ModelContextProtocol/Authentication/HttpClientExtensions.cs

Lines changed: 0 additions & 67 deletions
This file was deleted.

0 commit comments

Comments
 (0)