tamer
tamer copied to clipboard
`addAuthentication` uses SttpRequest but zio env is optional
https://github.com/laserdisc-io/tamer/blob/8c8c40ff1f17b3735d44349797257600bdf31f15/example/src/main/scala/tamer/rest/RESTCustomAuth.scala#L21 This can result in code like this for custom auth:
val authentication: Authentication[Any] = new Authentication[Any] {
override def addAuthentication(request: SttpRequest, supplementalSecret: Option[String]): SttpRequest =
// ...
}
A suggestion is to make the type parameter -R <: SttpClient
or to make authentication independent from any particular client.