Update call-web-api.md (#33894)

pull/33893/head
Mark Bundschuh 2024-10-21 16:44:15 -04:00 committed by GitHub
parent cdb66bb017
commit 431f4a58b7
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 2 deletions

View File

@ -520,7 +520,7 @@ If you're calling an external web API (not in the same URL space as the client a
```csharp
builder.Services.AddHttpClient("WebAPI", client =>
client.BaseAddress = new Uri(https://localhost:5001));
client.BaseAddress = new Uri("https://localhost:5001"));
```
In the following component code:
@ -618,7 +618,7 @@ If you're calling an external web API (not in the same URL space as the client a
```csharp
builder.Services.AddHttpClient<ForecastHttpClient>(client =>
client.BaseAddress = new Uri(https://localhost:5001));
client.BaseAddress = new Uri("https://localhost:5001"));
```
Components inject the typed <xref:System.Net.Http.HttpClient> to call the web API.