Create a Client that Depends on HttpClient

public interface IApiClient 
{
	...
}

public class ApiClient : IApiClient 
{
	private readonly HttpClient client;
	public ApiClient(HttpClient client) => this.client = client;

	... things that interact with client ...
}

Register the Client at Startup

public class Startup 
{
	...
	public void ConfigureServices(IServiceCollection services)
	{
		...
		services.AddHttpClient<IApiClient, ApiClient>();
		...
	}
	...
}

What if I need to manipulate the client?

For example what if you need to add a base address to the client?

public class Startup 
{
	...
	public void ConfigureServices(IServiceCollection services)
	{
		...
		services.AddHttpClient<IApiClient, ApiClient>(client =>
		{
			client.BaseAddress = new Uri("<<the url for the api>>");
		});
		...
	}
	...
}