Skip to content
New issue

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

Invalid Auth Key Error #41

Closed
brettcomardelle opened this issue Jul 29, 2017 · 4 comments
Closed

Invalid Auth Key Error #41

brettcomardelle opened this issue Jul 29, 2017 · 4 comments

Comments

@brettcomardelle
Copy link

brettcomardelle commented Jul 29, 2017

I am using a correct api key and api secret, but it just isn't working. I keep getting the InvalidAuthKeyError message. I am using Ruby 2.4.

@mattdperkins
Copy link

mattdperkins commented Jul 31, 2017

I was having an auth error as well using the basic info from the readme.

require 'bitfinex-api-rb'  

require_relative 'config'  

client = Bitfinex::Client.new  

client.account_info  

irb(main):022:0> client.account_info  
Bitfinex::InvalidAuthKeyError: Bitfinex::InvalidAuthKeyError  
	from /usr/local/share/gems/gems/bitfinex-rb-0.0.11/lib/bitfinex/authenticated_rest.rb:6:in   `authenticated_post'  
	from /usr/local/share/gems/gems/bitfinex-rb-0.0.11/lib/bitfinex/account_info.rb:11:in `account_info'  
	from (irb):22  
	from /usr/bin/irb:11:in `<main>' 

Solved it by changing the secret and key setup slightly:

Bitfinex::Client.configure do |conf|  
  conf.secret = "xxxxxxxxx"  
  conf.api_key = "xxxxxxxxx"  
end  
` ``



@MonsieurLanza
Copy link

MonsieurLanza commented Aug 3, 2017

ENV[...] is an environment variable. You should not keep your secrets in the code, instead you may keep it in a .env file. This what the example in the readme is for.

@ilyacherevkov
Copy link

ilyacherevkov commented Aug 15, 2017

I'm having the same issue with WS v2 occasionally. It just not passing authentication from time to time.

@f3rno
Copy link
Contributor

f3rno commented Nov 13, 2018

I'm closing this as it is outdated, the repo has been (mostly) completely rewritten.

@f3rno f3rno closed this as completed Nov 13, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants