SparkPost / elixir-sparkpost

SparkPost client library for Elixir https://developers.sparkpost.com
Apache License 2.0
44 stars 13 forks source link

Add support for OAuth 1.0 or decouple HTTP client from base lib #15

Open mje113 opened 8 years ago

mje113 commented 8 years ago

Our SparkPost server is sitting behind an OAuth 1.0 gateway on our internal network. While adding OAuth support would probably be a heavyweight approach--I wonder if there would be some way to decouple the specific HTTP client being used, for a more bring-your-own approach?

richleland commented 8 years ago

That's an interesting idea @mje113 - we actually do this type of de-coupling with our PHP library. It's bring your own HTTP lib. Do you have any ideas around what that might look like architecturally? Is there a specific lib you have in mind that you'd want to use?

DavidAntaramian commented 8 years ago

@mje113 Jumping in here because I've been working on getting SparkPost moved over to HTTPoison on top of Hackney over HTTPotion on iBrowse (see #12). We've also discussed using dependency injection with on #13 which in theory would allow you to bring your HTTP communication layer.

mje113 commented 8 years ago

@DavidAntaramian Cool, I'll check that out. I managed to side-step my OAuth requirement for the time being so this issue fell off my immediate radar.