We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
With the switch to Faraday, it might make sense to offer signet as Faraday middleware rather than acting as a front-end to it. E.g.
client = Signet::OAuth2::Client.new... access_token = ... # get access token conn = Faraday.new do |builder| builder. user Signet::OAuth2::Client, access_token end conn.get(...)
(Copied from @sqrrrl's issue on the original Signet project.)
The text was updated successfully, but these errors were encountered:
I created a middleware that'll do this for you
class CredentialsMiddleware < Faraday::Middleware def on_request(env) options[:client].apply! env.request_headers end end credentials = Google::Auth::Credentials.default conn = Faraday.new(url: "...") do |c| c.use CredentialsMiddleware, client: credentials.client end
Sorry, something went wrong.
No branches or pull requests
With the switch to Faraday, it might make sense to offer signet as Faraday middleware rather than acting as a front-end to it. E.g.
(Copied from @sqrrrl's issue on the original Signet project.)
The text was updated successfully, but these errors were encountered: