Closed axelcxyz closed 1 year ago
I'd like to add Tesla.Middleware.Logger to the client when making requests. Is that possible?
client
It doesn't look like ExForce.Client.Tesla.build_client/2 supports it:
ExForce.Client.Tesla.build_client/2
https://github.com/chulkilee/ex_force/blob/4181e26c8514312099cdde6e153fdaf60d3abe53/lib/ex_force/client/tesla/tesla.ex#L34
I was also looking into whether I could add the Middleware to the client after I get it back, but I couldn't find a way to modify a Tesla.Client after it is built.
Tesla.Client
Thanks!
I see there is an open pull request for this:
https://github.com/chulkilee/ex_force/pull/71
I ended up using this approach: https://github.com/chulkilee/ex_force/pull/42#issuecomment-766766017
I'd like to add Tesla.Middleware.Logger to the
client
when making requests. Is that possible?It doesn't look like
ExForce.Client.Tesla.build_client/2
supports it:https://github.com/chulkilee/ex_force/blob/4181e26c8514312099cdde6e153fdaf60d3abe53/lib/ex_force/client/tesla/tesla.ex#L34
I was also looking into whether I could add the Middleware to the client after I get it back, but I couldn't find a way to modify a
Tesla.Client
after it is built.Thanks!