Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

UPS Price incorect #120

Open
shuhrat10 opened this Issue · 8 comments

3 participants

@shuhrat10

Return wrong price from API Server

UPS Online Calculator return 9.75
API Return 9.71

@packages = [ Package.new( 2, [10,10,10], :units => :imperial ) ]

  @origin = Location.new(  :country => 'US',
                        :state => 'DC',
                        :city => 'WASHINGTON',
                        :zip => '20015',
                        :address_type => 'residential')

  @destination = Location.new( :country => 'US',
                        :state => 'NY',
                        :city => 'BROOKLYN',
                        :zip => '11201',
                        :address_type => 'residential')
@csaunders
Collaborator

What is the difference between what we are generating and what the online calculator is generating?

Does the online generator give example XML on how to send the correct response? Until we get more information, all this issue tells us that we are using the API incorrectly somehow, but not how or why

@shuhrat10
@sachin004

Hi @shuhrat10
FYI by default pickup_type is set to "daily_pickup"(options[:pickup_type] || :daily_pickup), so you have manually pass pickup_type in options otherwise you will get the rates for wholesale instead of retail.

@csaunders
Collaborator

@sachin004 so if I understand correctly this isn't an actual bug but more a crappy documentation problem?

@sachin004

@csaunders Yes, you are correct its more of a documentation issue. It would be helpful for new developers if we could provide basic information(like assumptions that we are making in the code base), which helps to avoid to go through entire code base.

@sachin004

@csaunders I think this issue can be closed now.

@csaunders
Collaborator

:heart:Cool! Thanks for the feedback.:heart:

I'm going to keep the issue open since there is a problem, it's just not a technical one. Updating docs will be required to close this.

@shuhrat10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.