When the api is behind basic authentication or some other authentication there is no way of configuring this.
In the DependencyInjectin Extension you create a guzzle client, but you might want to use a guzzle bundle like eightpoints/guzzle-bundle so people can configure their guzzle client.
This way people can configure multiple clients and when they do they can configure all kinds of things, like a username and password for a protected api.