You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Mar 11, 2024. It is now read-only.
<Chargify2::Response:0x007f8c1d878ec0 @resource=#<Chargify2::Customer>, @meta=#<Hashie::Mash errors=[#<Hashie::Mash attribute=nil kind="not_found" message="The requested Customer could not be found.">]>, @status_code=nil, @errors=[#<Hashie::Mash attribute=nil kind="not_found" message="The requested Customer could not be found.">]>
When I tried to hit the api directly, i could see status_code being sent in the chargify api response. So guessing the issue to be in the gem.
curl -v -u <api_id>:x -H Accept:application/json -H Content-Type:application/json https://mavenhive-ghuk.chargify.com/customers/1
* Hostname was NOT found in DNS cache
* Trying 54.244.7.151...
* Connected to mavenhive-ghuk.chargify.com (54.244.7.151) port 443 (#0)
* TLS 1.2 connection using TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256
* Server certificate: *.chargify.com
* Server certificate: COMODO RSA Organization Validation Secure Server CA
* Server certificate: COMODO RSA Certification Authority
* Server certificate: AddTrust External CA Root
* Server auth using Basic with user 'dvLih3EFHkpluaBrGP7A'
> GET /customers/1 HTTP/1.1
> Authorization: Basic ZHZMaWgzRUZIa3BsdWFCckdQN0E6eA==
> User-Agent: curl/7.37.1
> Host: mavenhive-ghuk.chargify.com
> Accept:application/json
> Content-Type:application/json
>
< HTTP/1.1 404 Not Found
< Cache-Control: no-cache, private
< Content-Type: application/json; charset=utf-8
< Date: Wed, 04 Mar 2015 11:27:09 GMT
< P3p: CP="NOI ADM DEV PSAi COM NAV OUR OTRo STP IND DEM"
* Server nginx + Phusion Passenger is not blacklisted
< Server: nginx + Phusion Passenger
< Set-Cookie: _chargify_session=BAh7CEkiD3Nlc3Npb25faWQGOgZFVEkiJTRlMjNlMGVjZGYzOWRkZDAyYmVlZDViOGJmNGM2MzhjBjsAVEkiF3NlbGxlcl9jcmVkZW50aWFscwY7AEZJIgGAZTJlYjBjOTViOWRkZWY2NWYwYTNlZDk4NDYwYmNjN2FlYzFmNzJmNjgxNWRmOWYyMTI4MGJjODgzMmY2NzIyNTczMzlhMjA2NzI5YjU4Y2RiM2RlOWY3YjJhN2YwZTIwMDQ2NzE5YmY0YTM5M2IxYjVlMmY0MzY4MTE0YjU2YzAGOwBGSSIac2VsbGVyX2NyZWRlbnRpYWxzX2lkBjsARmkCsjw%3D--b0cc8c93ff92f3de8d3abf63671acb887fa8b82b; domain=.chargify.com; path=/; secure; HttpOnly
< Status: 404 Not Found
< X-Frame-Options: SAMEORIGIN
< X-Powered-By: Phusion Passenger
< X-Rack-Cache: miss
< X-Ratelimit-Limit: 1000000
< X-Ratelimit-Remaining: 999982
< X-Ratelimit-Reset: 1425513600
< X-Request-Id: f2ab412e-9ab7-464a-88df-695e555b852a
< X-Runtime: 0.029060
< X-Ua-Compatible: IE=Edge,chrome=1
< Content-Length: 1
< Connection: keep-alive
<
* Connection #0 to host mavenhive-ghuk.chargify.com left intact
The text was updated successfully, but these errors were encountered:
I am @MonikaMahanthappa's colleague and I ran into same issue (nil @status_code resulting in response.successful? to be false even though the API call was successful). This time, it was the POST /allocations API of V2.
I suspect something has changed recently in API V2 which is causing this bug in this gem. I will try to report to Chargify support and see what I can find.
Meanwhile, we have stopped using this gem and fallen back to our custom Chargify api client.
In case of
404
status_code
is not getting set in response. Im are usingapi_v2
branch.chargify = Chargify2::Client.new(api_id: <masked>, api_password: <masked>, base_uri: 'https://api.chargify.com/api/v2')
chargify.customers.read(1)
<Chargify2::Response:0x007f8c1d878ec0 @resource=#<Chargify2::Customer>, @meta=#<Hashie::Mash errors=[#<Hashie::Mash attribute=nil kind="not_found" message="The requested Customer could not be found.">]>, @status_code=nil, @errors=[#<Hashie::Mash attribute=nil kind="not_found" message="The requested Customer could not be found.">]>
When I tried to hit the api directly, i could see status_code being sent in the chargify api response. So guessing the issue to be in the gem.
The text was updated successfully, but these errors were encountered: