6

I am using the Balanced ruby gem in my rails app for payment integration.

I am submitting card information and getting valid response. Then I send card information to my controller and in that I am creating buyer using card_uri.

buyer = Balanced::Marketplace.my_marketplace.create_buyer(@member.email, card_uri)

but, I am getting this error:

Faraday::Error::TimeoutError (execution expired):

Can anyone tell me what's wrong? Thanks in advance.

mjallday
  • 9,796
  • 9
  • 51
  • 71
Kiran Chaudhari
  • 198
  • 2
  • 10
  • Can you turn on debug logging and give us the header outputs? To do so, just configure your Balanced gem client with `Balanced.configure(:api_key, :logger => Rails.logger)` and set your logging level to DEBUG – Mahmoud Abdelkader Oct 19 '12 at 16:06

1 Answers1

10

I've done some more digging in this issue, it could be that it's a transient network slowness. The settings are pretty strict for Faraday, so maybe we can loosen them up a bit.

When configuring Balanced, try this:

Balanced.configure('API_KEY_STRING', :connection_timeout => 30, 
                                     :read_timeout => 30)

Hope this helps.

Mahmoud Abdelkader
  • 23,011
  • 5
  • 41
  • 54