shippo-ruby-client
shippo-ruby-client copied to clipboard
Rescue gracefully not found error for detailed responses
When creating a manifest with invalid data and bad request error should be returned, GoShippo API instead returns 404 Not found error. Gem should be able to rescue such errors until proper error will be returned on server side.
Thanks for making a pull request! We are still attempting to figure out how to handle SDK support (especially for this gem). There are a number of things that haven't been included in this API wrapper (like our orders endpoint-> https://goshippo.com/docs/reference#orders).
I've been working with manifests quite a bit recently with customers and think a more specific error response code would be helpful!
What sort of error response message were you expecting?
Was there something wrong with the manifest request that we should have surfaced for you?
For example you can only setup a manifest (aka scanform) with USPS for domestic mail (not PR or MIL addresses) but currently we don't out out the difference between those and say a tracking number that has already been included in another manifest.
@jfriedr GoShippo API returns such error and 404 not found.
"Invalid transactions (transaction_id) for manifest request. Please check that the carrier (carrier) matches, that the transactions are of the same date (date), that the transactions have the correct zip code (zip code), and that the transactions have not been assigned to a different manifest."
But the gem doesn't handle this properly and loses such errors. As you can see such errors can happen if a shipment has different pickup date, address zip code or carrier than manifest







