Skip to content

Commit 17c6335

Browse files
committed
Add missing EndpointExecutor constructor for URL + Auth via ZIO
1 parent dde583e commit 17c6335

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

zio-http/shared/src/main/scala/zio/http/endpoint/EndpointExecutor.scala

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,16 @@ object EndpointExecutor {
130130
): EndpointExecutor[Any, Auth, ReqEnv] =
131131
EndpointExecutor(client, EndpointLocator.fromURL(location), ZIO.succeed(auth))
132132

133+
@nowarn("msg=deprecated")
134+
def apply[R, Auth, ReqEnv](
135+
client: ZClient[Any, ReqEnv, Body, Throwable, Response],
136+
location: URL,
137+
authProvider: ZIO[R, Nothing, Auth],
138+
)(implicit
139+
trace: Trace,
140+
): EndpointExecutor[R, Auth, ReqEnv] =
141+
EndpointExecutor(client, EndpointLocator.fromURL(location), authProvider)
142+
133143
final case class Config(url: URL)
134144
object Config {
135145
import zio.{Config => ZConfig}

0 commit comments

Comments
 (0)