Git Product home page Git Product logo

fedex's Introduction

  • ๐Ÿ‘‹ Hi, Iโ€™m @jazminschroeder
  • ๐Ÿ‘€ Iโ€™m interested in empowering engineering teams to deliver software while growing personally and professionally
  • ๐ŸŒฑ Iโ€™m currently learning how to align my teams as part of a bigger organization while keeping a generative culture
  • ๐Ÿ’ž๏ธ Iโ€™m looking to collaborate on team organizational structures
  • ๐Ÿ“ซ How to reach me [email protected]

fedex's People

Contributors

abundnce10 avatar ajsharma avatar akosipc avatar alexqueue avatar assafgelber avatar axlekb avatar bradediger avatar chirag7jain avatar cyu avatar dhassler avatar dnajd avatar geermc4 avatar jazminschroeder avatar jlambert121 avatar jonathandean avatar jordanbyron avatar jpowers avatar mrpollo avatar mvaneyken avatar parndt avatar piyushkp avatar rywall avatar sborsje avatar scottbartell avatar smartacus avatar square-build-bot avatar strathmeyer avatar torbjon avatar treenewbee avatar yevgenko avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

fedex's Issues

License missing from gemspec

RubyGems.org doesn't report a license for your gem. This is because it is not specified in the gemspec of your last release.

via e.g.

  spec.license = 'MIT'
  # or
  spec.licenses = ['MIT', 'GPL-2']

Including a license in your gemspec is an easy way for rubygems.org and other tools to check how your gem is licensed. As you can imagine, scanning your repository for a LICENSE file or parsing the README, and then attempting to identify the license or licenses is much more difficult and more error prone. So, even for projects that already specify a license, including a license in your gemspec is a good practice. See, for example, how rubygems.org uses the gemspec to display the rails gem license.

There is even a License Finder gem to help companies/individuals ensure all gems they use meet their licensing needs. This tool depends on license information being available in the gemspec. This is an important enough issue that even Bundler now generates gems with a default 'MIT' license.

I hope you'll consider specifying a license in your gemspec. If not, please just close the issue with a nice message. In either case, I'll follow up. Thanks for your time!

Appendix:

If you need help choosing a license (sorry, I haven't checked your readme or looked for a license file), GitHub has created a license picker tool. Code without a license specified defaults to 'All rights reserved'-- denying others all rights to use of the code.
Here's a list of the license names I've found and their frequencies

p.s. In case you're wondering how I found you and why I made this issue, it's because I'm collecting stats on gems (I was originally looking for download data) and decided to collect license metadata,too, and make issues for gemspecs not specifying a license as a public service :). See the previous link or my blog post about this project for more information.

How do you run the tests on this gem?

Fantastic Gem Guys! Just getting started with it.

I added my credentials to the sample config file you have and want to run the specs. I get an error because rake is not included in the gemspec, but the tests depend on it. Is this on purpose or should I fix and do a pull request?

outdated httparty and nokogiri dependencies make fedex gem hard to use with newer code

Apologies if this isn't your cup of tea, but I've been enjoying developing a Spree store and using Fedex to print labels for most of the past year. Recent updates to Spree's dependencies have left me unable to use fedex due to its being pinned to httparty 0.11 and nokogiri 1.5. I'm currently using jpowers/fedex and it appears to be working for me with the latest httparty and nokogiri.

Can we cut a new release of the fedex gem that requires the latest releases of its dependencies? If not, I'm open to suggestions on how I could help meet my own need without using much of your time.

Thanks!

Does this ruby gem support FedExSearchLocationsRequest?

Does this ruby gem support for FedExSearchLocationsRequest?
How can we find the nearest fedex locations from an address?

Specifies the criterion that may be used to search for FedEx locations. Valid values are:
๏‚ท ADDRESS
๏‚ท GEOGRAPHIC_COORDINATES
๏‚ท PHONE_NUMBER

Rate class mistyped 'billing'

The rate class has total_billing_weight mistyped (missing an L):

attr_accessor :service_type, :rate_type, :rate_zone, :total_biling_weight...

This makes the @total_billing_weight value inaccessible from outside the class.

CustomerReference

I am having a hell of a time using the CustomerReference options to generate the "Ref:" line on the fedex label.

currently i am trying this:

def customer_references s
{
type: 'CUSTOMER_REFERENCE',
value: "#{s.key} - #{s.li_model.upcase || ''}"
}
end

packages << {
weight: { units: 'LB', value: weight },
customer_references: customer_references(s),
dimensions: { units: 'IN', length: length, width: width, height: height }
}

and am getting the error:
"customerReference value is invalid for customer reference 2 in requestedPackage 1"

I see no test coverage for customer reference support. Does anyone have any recent experience in trying to do such a thing?

I'm just asking incase someone has some insight for me before I dig deeper and fork the gem to add/fix such functionality.

Update Service id pickup for pickup_availability request.

Hi Team,

When I execute this:

fedex.pickup_availability(:country_code => 'IN',
:postal_code => '400061',
:request_type => 'FUTURE_DAY',
:dispatch_date => dispatch_date,
:carrier_code => 'FDXE')

I got error:
Fedex::RateError
{"Fault"=>{"faultcode"=>"soapenv:Server", "faultstring"=>"Schema validation failed for request.", "detail"=>{"fault"=>{"errorCode"=>"5", "reason"=>"Schema validation failed for request.", "details"=>{"ValidationFailureDetail"=>{"message"=>"string value 'pickup' is not a valid enumeration value for ServiceIdType in namespace http://fedex.com/ws/pickup/v5", "xmlLocation"=>{"ServiceId"=>"pickup"}}}}}}}

Need to change service_id 'pickup' to 'disp'

PR for this:
https://github.com/jazminschroeder/fedex/pull/95/files

Thanks

httparty update

Using the Fedex gem with aws-sdk is causing issues since fedex is keyed ~0.8.0 and aws-sdk ~0.9.0. Have you looked into/considered upgrading the gemspec to ~0.9.0 for httparty?

How to get expected arrival time in fedex rate() ?

Currently we can not get the expected arrival time/transit time in fedex.rate() method .
It does not show for all service types, but it shows for only FEDEX_GROUND and GROUND_HOME_DELIVERY .

If we go through the fedex site and make a quote it returns the transit time . Please look into this . If there is any other method and not listed in the readme file, please update .

Can't Load Fedex

I've been trying to install this gem on Ruby v2.1.2p95 & Rails v 4.0.8 - it seems like the installation goes fine; however, when I go to test it I keep getting the following error. I've uninstalled and reinstalled a handful of times, and I'm just at a loss why it wont load.

I'd really appreciate any help, your project looks really cool and I'd love to try it out!

Cheers,
AS

LoadError: cannot load such file -- fedex
    from /Library/Ruby/Gems/2.0.0/gems/activesupport-4.0.8/lib/active_support/dependencies.rb:229:in `require'
    from /Library/Ruby/Gems/2.0.0/gems/activesupport-4.0.8/lib/active_support/dependencies.rb:229:in `block in require'
    from /Library/Ruby/Gems/2.0.0/gems/activesupport-4.0.8/lib/active_support/dependencies.rb:214:in `load_dependency'
    from /Library/Ruby/Gems/2.0.0/gems/activesupport-4.0.8/lib/active_support/dependencies.rb:229:in `require'
    from (irb):13
    from /Library/Ruby/Gems/2.0.0/gems/railties-4.0.8/lib/rails/commands/console.rb:90:in `start'
    from /Library/Ruby/Gems/2.0.0/gems/railties-4.0.8/lib/rails/commands/console.rb:9:in `start'
    from /Library/Ruby/Gems/2.0.0/gems/railties-4.0.8/lib/rails/commands.rb:62:in `<top (required)>'

How I am supposed to authenticate?

I've been trying to authenticate to the API to get shipping rates, however I keep getting Fedex::RateError: Authentication Failed. I'm using these credentials I got from fedex:

fedex_credentials

So to login:

fedex = Fedex::Shipment.new(
  key: 'key',
  password: 'the password I use to login to fedex (?)',
  account_number: 'account_number',
  meter: 'meter',
  mode: 'development',
  test: true # doesn't make any difference
)

I'm clueless, I'd appreciate any help.

Service ID for Pickup Requests

Hi,

I was trying to use the pickup functionality to create an example pickup request, but ran into a soap validation error saying: "string value 'pickup' is not a valid enumeration value for ServiceIdType" In the Fedex Webservice Developer Guide pickup example the version element has the following values:

<v9:Version>
        <v9:ServiceId>disp</v9:ServiceId>
        <v9:Major>9</v9:Major>
        <v9:Intermediate>0</v9:Intermediate>
        <v9:Minor>0</v9:Minor>
</v9:Version>

If I use this service id in pickup.rb my request is processed correctly. I just started working with the gem so maybe I'am missing something. Is there someone with more experience with pickup requests, who can explain the different service ids?

Regards,
Karsten

Can anyone please suggest me the way to set declared value?

Hi all

Can anyone please suggest me the way to set declared value?

More basically, The customer selects the insurance after the package information. This selected insurance should be supplied to fedex.
Earlier in a old plugin we could not able to pass for the same declared value.

Thanks
Any help is appreciated

No Support for Freight Rates

Hi there,

passing in :service_type => "FEDEX_FREIGHT_ECONOMY" when calling
Fedex::Shipment#rate
gives the following error.

Either a FedEx Freight or Alternate account number and associated address is required for service type FEDEX_FREIGHT_ECONOMY

In order to support freight shipments, the credentials class needs a data member for :freight_account_number

What's the benefit of Fedex::Label vs the Fedex::Request::Label

Thanks for this great library. It's mostly well thought out and to the point.

I do have an issue with the Fedex::Label object: I need to get the tracking number from the Label and that requires some kind of change to the code because the Fedex::Label object is not passed the necessary information when Fedex::Request::Label initializes it. I see one possible solution here: https://github.com/jordanbyron/fedex/blob/560b0896772c3b3c0d38923d85f9302311cb6948/lib/fedex/request/label.rb. My inclination is to eliminate the Fedex::Label class outright. There is a lot more information besides the TrackingNumber that is currently lost when Fedex::Request::Label returns a Fedex::Label. I think the expedient solution is to do the simple thing and let Fedex::Request::Label represent itself. The Fedex::Request::Label will keep and expose all of the response so that all of the response information is available.

If I make this change and the maintainers don't agree, then my fork will slowly evolve in another direction. I'd rather that did not happen. What do you think?

Type error causes if FedEx returns multiple address validation suggestions

It's possible that the address validation service can return multiple suggestions. When this happens it results in the following error:

can't convert Symbol into Integer
/app/vendor/bundle/ruby/1.9.1/gems/fedex-3.0.0/lib/fedex/address.rb:9:in `[]'
/app/vendor/bundle/ruby/1.9.1/gems/fedex-3.0.0/lib/fedex/address.rb:9:in `initialize'
/app/vendor/bundle/ruby/1.9.1/gems/fedex-3.0.0/lib/fedex/request/address.rb:21:in `new'
/app/vendor/bundle/ruby/1.9.1/gems/fedex-3.0.0/lib/fedex/request/address.rb:21:in `process_request'
/app/vendor/bundle/ruby/1.9.1/gems/fedex-3.0.0/lib/fedex/shipment.rb:43:in `validate_address'

This is because the structure of response[:address_validation_reply][:address_results][:proposed_address_details] on line 19 of lib/fedex/request/address.rb looks like this (client information hidden):

{
  :address_validation_reply => {
    :highest_severity => "SUCCESS",
    :notifications => {
      :severity => "SUCCESS",
      :source => "wsi"
    },
    :version => {
      :service_id => "aval",
      :major => "2",
      :intermediate => "0",
      :minor => "0"
    },
    :reply_timestamp => "2013-07-17T22:32:44.372Z",
    :address_results => {
      :proposed_address_details => [
        {
          :score => "0",
          :changes => ["MODIFIED_TO_ACHIEVE_MATCH", "APARTMENT_NUMBER_REQUIRED"],
          :residential_status => "BUSINESS",
          :delivery_point_validation => "CONFIRMED",
          :address => {
            :street_lines => "REDACTED",
            :city => "REDACTED",
            :state_or_province_code => "REDACTED",
            :postal_code => "REDACTED",
            :country_code => "REDACTED"
          },
          :removed_non_address_data => nil
        },
        {
          :score => "0",
          :changes => ["MODIFIED_TO_ACHIEVE_MATCH", "APARTMENT_NUMBER_REQUIRED"],
          :residential_status => "UNDETERMINED",
          :delivery_point_validation => "UNCONFIRMED",
          :address => {
            :street_lines => "REDACTED",
            :city => "REDACTED",
            :state_or_province_code => "REDACTED",
            :postal_code => "REDACTED",
            :country_code => "REDACTED"
          },
          :removed_non_address_data => nil
        }
      ]
    }
  }
}

So you can see that it is an array of hashes instead of the singular hash it expects.

I had some trouble running the tests so I didn't feel comfortable trying a real solution yet so here's the quick hack I'm using temporarily (tested in our app's tests for now): stitchfix@785cd33 Obviously this isn't a real solution but it does keep it from breaking.

A real solution likely involves allowing it to handle multiple results rather than just taking the first one and would of course need tests, which I don't have the time today to solve for why they aren't running for me.

In particular this was a case of leaving off an "East" or "West" on the street name so I'm sure that's a common cause.

Transit time estimation actually generates a shipment and label.

According to fedex if you do as your example shows:

ship = fedex.ship(:shipper=>shipper,
:recipient => recipient,
:packages => packages,
:service_type => "FEDEX_GROUND",
:shipping_options => shipping_options)
puts ship[:completed_shipment_detail][:operational_detail] [:transit_time]

This will actually generate a shipment on your account that fedex will be expecting to pick up.
I'm working on this in my own fork of the gem, and I post an update here when done.

Can we get 2 types of labels from fedex API?

Can we get 2 types of labels from fedex API?

We can get one label in either .pdf or .pcx format . How can we get both types of label in single label request ?

Currently the thermal printer generating by passing image_type => "EPL2"

example_spec = {
:image_type => "EPL2",
:label_stock_type => "STOCK_4X6"
}

label = fedex.label(:filename => "my_dir/example_epl2.pcx",
:shipper=>shipper,
:recipient => recipient,
:packages => packages,
:service_type => "FEDEX_GROUND",
:shipping_options => shipping_options,
:label_specification => example_spec)

The file saved in .pcx format . But the file could not open in any tool . Tried to open in linux but it says invalid pcx file .

How to resolve "Airbill is not allowed for Origin Country" issue

Hi,

Kindly find below the request sent and response received.

<RateRequest xmlns="http://fedex.com/ws/rate/v13"> <WebAuthenticationDetail> <UserCredential> <Key>XXX</Key> <Password>XXX</Password> </UserCredential> </WebAuthenticationDetail> <ClientDetail> <AccountNumber>XXX</AccountNumber> <MeterNumber>XXX</MeterNumber> <Localization> <LanguageCode>en</LanguageCode> <LocaleCode>us</LocaleCode> </Localization> </ClientDetail> <Version> <ServiceId>crs</ServiceId> <Major>13</Major> <Intermediate>0</Intermediate> <Minor>0</Minor> </Version> <ReturnTransitAndCommit>true</ReturnTransitAndCommit> <RequestedShipment> <DropoffType>REGULAR_PICKUP</DropoffType> <ServiceType>FEDEX_GROUND</ServiceType> <PackagingType>YOUR_PACKAGING</PackagingType> <Shipper> <Contact> <PersonName>Sender</PersonName> <CompanyName>Company</CompanyName> <PhoneNumber>EEEEEEEEEEE</PhoneNumber> </Contact> <Address> <StreetLines>Main Street</StreetLines> <City>Delhi</City> <StateOrProvinceCode>DL</StateOrProvinceCode> <PostalCode>110001</PostalCode> <CountryCode>IN</CountryCode> </Address> </Shipper> <Recipient> <Contact> <PersonName>customer</PersonName> <CompanyName>vghbjn</CompanyName> <PhoneNumber>EEEEEEEEEE</PhoneNumber> </Contact> <Address> <StreetLines>8th main</StreetLines> <City>Bangalore</City> <StateOrProvinceCode>KA</StateOrProvinceCode> <PostalCode>560045</PostalCode> <CountryCode>IN</CountryCode> <Residential>true</Residential> </Address> </Recipient> <ShippingChargesPayment> <PaymentType>SENDER</PaymentType> <Payor> <ResponsibleParty> <AccountNumber>XXX</AccountNumber> <Contact> <PersonName>Sender</PersonName> <CompanyName>Company</CompanyName> <PhoneNumber>EEEEEEEEEE</PhoneNumber> </Contact> </ResponsibleParty> </Payor> </ShippingChargesPayment> <RateRequestTypes>ACCOUNT</RateRequestTypes> <PackageCount>1</PackageCount> <RequestedPackageLineItems> <GroupPackageCount>1</GroupPackageCount> <Weight> <Units>LB</Units> <Value>2</Value> </Weight> <Dimensions> <Length>10</Length> <Width>5</Width> <Height>4</Height> <Units>IN</Units> </Dimensions> </RequestedPackageLineItems> </RequestedShipment> </RateRequest>

response:
{"RateReply"=>{"HighestSeverity"=>"ERROR", "Notifications"=>{"Severity"=>"ERROR", "Source"=>"crs", "Code"=>"879", "Message"=>"Airbill is not allowed for Origin Country.", "LocalizedMessage"=>"Airbill is not allowed for Origin Country."}, "Version"=>{"ServiceId"=>"crs", "Major"=>"13", "Intermediate"=>"0", "Minor"=>"0"}}}

Support for Saturday delivery

I'm a bit new to the gem, so please forgive me if I missed it, but there doesn't seem to be support for upgrading shipping to Saturday delivery as described http://www.fedex.com/us/developer/product/WebServices/MyWebHelp_August2010/Content/Proprietary_Developer_Guide/Rate_Services_conditionalized.htm

I only see code for COD and Return shipments here

def add_special_services(xml)

I'm happy to write a pull request if needed, but wanted to make sure it wasn't already in place

Customs Value is required error on create shipment

Hi,

When I try to create an international shipment i get a "Customs Value is required" error.

Is there a way to declare the value of the shipment? Setting insured_value on the package didn't work.

Thank you,

Reinier

IS THIS BEING MAINTAINED?

Hello, I just want to ask if this gem is being maintained? I'm planning to use this gem for an app. Huge thanks for the reply.

RubyGems version is stuck at 3.6.1

Hey guys,

nice work with your Fedex gem!

Since I would like to use the Delete request - are you going to release a current gem version on RubyGems anytime soon? The RG version doesn't have the Delete request, yet.

Cheers!

Support shipment LabelSpecification PrintedLabelOrigin element

I'll be working on this PR over the next few days as I have time, but wanted to give a heads up:

image
image

        <q0:PrintedLabelOrigin>
            <q0:Contact>
              <q0:CompanyName>Company Name</q0:CompanyName>
              <q0:PhoneNumber>11111111111</q0:PhoneNumber>
            </q0:Contact>
            <q0:Address>
              <q0:StreetLines>123 Main St.</q0:StreetLines>
              <q0:City>Cincinnati</q0:City>
              <q0:StateOrProvinceCode>OH</q0:StateOrProvinceCode>
              <q0:PostalCode>45230</q0:PostalCode>
              <q0:CountryCode>US</q0:CountryCode>
            </q0:Address>
          </q0:PrintedLabelOrigin>

Pickup Service

Is there a way to schedule a pickup with this ruby gem? If not I wouldn't mind submitting a pull request.

README references shipping_details instead of shipping_options

If you look at https://github.com/jazminschroeder/fedex/blob/master/lib/fedex/request/base.rb#L49 the code actually uses shipping_options instead of shipping_details. However, the README has many references to a shipping_details option.

It seems none of my options were being passed until I changed this value in my code. It was just using the default values.

I can probably do a pull request at some point but repo has some other changes not ready for a PR as well and I don't immediately see how to separate them.

Weight error

shipper = { :name => "Developer",
:company => "Sunlight",
:phone_number => "555-555-5555",
:address => "450 Grim Ln",
:city => "York",
:state => "PA",
:postal_code => "17406",
:country_code => "US" }

recipient = { :name => "Ty Po",
:company => "Sunfarm",
:phone_number => "555-555-5555",
:address => "5913-C NE 127th Ave, Suite 800 Suite 800",
:city => "Vancouver",
:state => "WA",
:postal_code => "98682",
:country_code => "US",
:residential => "true" }

packages = []

packages << {
:weight => {:units => "LB", :value => 160},
:dimensions => {:length => 10, :width => 5, :height => 4, :units => "IN" }
}

rate = fedex.rate(:shipper=>shipper,
:recipient => recipient,
:packages => packages,
:service_type => "GROUND_HOME_DELIVERY"
)

Getting Package 1 - Weight is missing or invalid error. How to insert quantity here if I have 2 same package?

Tracking Issue

I am trying to test the tracking API, but getting the following error:

Fedex::RateError: Schema validation failed for request.

I have not really played with the fedex gem before, I've inherited existing code so please forgive me if this is something simple.

Thanks.

Fedex is complaining about the order of the label_specifications

Expected element 'LabelFormatType@http://fedex.com/ws/ship/v10' instead of 'ImageType@http://fedex.com/ws/ship/v10' here in element LabelSpecification

Started getting that after 0ad0aa2 , not exactly sure why i thought it wasn't a problem (this is from my comments in the commit) but it is

I compared the XML returned before and after that and the only difference is the date (of course) it now has a and also the order of was different, changed the definition of it and it works now

before

        @label_specification = {
          :label_format_type => 'COMMON2D',
          :image_type => 'PDF',
          :label_stock_type => 'PAPER_LETTER'
        }

after

        @label_specification = ActiveSupport::OrderedHash.new
        @label_specification[:label_format_type] = 'COMMON2D'
        @label_specification[:image_type] = 'PDF'
        @label_specification[:label_stock_type] = 'PAPER_LETTER'

PR comming in a sec.

not able to track with tracking id

I just created a shipment in development mode, my shipment got created i am able to parse tracking number also, but when i track by tracking number, it is saying Fedex::RateError: This tracking number cannot be found. Please check the number or contact the sender.

I used the example given in README.

Please help.

transit_time=nil response for all shipping service types except ground

Hey Guys,

I seem to be having trouble requesting Transit times - for both fedex.ship and fedex.rate requests I'm returning @transit_time=nil for shipping service types except FEDEX_GROUND

It this a known limitation of this gem, does anyone know how to return transit time along with rates?

In the FedEX Documentation I found this:

Use the optional ReturnTransitAndCommit element to include transit time information in the reply. FedEx Express information will include the day and date the package will be delivered, based on the ship date you specified. The FedEx Ground response will describe the number of business days required for the package delivery

Thanks!

Unable to use track function

fedex = Fedex::Shipment.new(:key => FEDEX_TEST_KEY, :password => FEDEX_TEST_PASSWORD, :account_number => FEDEX_TEST_ACCOUNT, :meter => FEDEX_TEST_METER, :mode => 'development')

fedex.track(:tracking_number => "1234567890123")

Getting RateError

response
Fedex::RateError: {:fault=>{:faultcode=>"SOAP-ENV:Server", :faultstring=>{:content=>"Fault", :lang=>"en"}, :detail=>{:cause=>"UnrecoverableClientError", :code=>"SchemaError", :desc=>"validation failure for TrackRequestError:cvc-datatype-valid.1.2.1: '' is not a valid value for 'boolean'.\ncvc-type.3.1.3: The value '' of element 'IncludeDetailedScans' is not valid."}}}

Please help

Attaching Labels Using Paperclip

When attempting to attach a label with paperclip I am getting
Paperclip::AdapterRegistry::NoHandlerError

class Ticket < ActiveRecord::Base
    has_attached_file :fedex_label, content_type: { content_type: "application/pdf" }

I am putting my code here:

begin
     label = fedex.label(:filename => "tmp/#{@ticket.id}_ship_label.pdf",
                      :shipper=>shipper,
                      :recipient => recipient,
                      :packages => packages,
                      :service_type => "FEDEX_GROUND",
                      :shipping_options => shipping_options,
                      :label_specification => size_settings)
     @ticket.fedex_label = label.file_name
     @ticket.save!
     @track_number =  label.response_details[:completed_shipment_detail][:completed_package_details][:tracking_ids][:tracking_number].to_s
   rescue Fedex::RateError => e
     @fedex_error = e
   end

Is anyone else having a problem with this?

Opening and ending tag mismatch

Hello,

I use the gem in order to generate labels, everything was working fine a few weeks ago, but it seems that something has changer as I now get this error : Opening and ending tag mismatch: hr line 1 and BODY on any Fedex::Shipment method (I tried label, rate and ship and they all give the same error).

Here is the full trace. Do you have any idea what's happening? Thanks in advance.

multi_xml (0.5.5) lib/multi_xml/parsers/nokogiri.rb:15:in `parse'
multi_xml (0.5.5) lib/multi_xml.rb:138:in `parse'
httparty (0.13.1) lib/httparty/parser.rb:112:in `xml'
httparty (0.13.1) lib/httparty/parser.rb:136:in `parse_supported_format'
httparty (0.13.1) lib/httparty/parser.rb:103:in `parse'
httparty (0.13.1) lib/httparty/parser.rb:67:in `call'
httparty (0.13.1) lib/httparty/request.rb:296:in `parse_response'
httparty (0.13.1) lib/httparty/request.rb:266:in `block in handle_response'
httparty (0.13.1) lib/httparty/response.rb:23:in `call'
httparty (0.13.1) lib/httparty/response.rb:23:in `parsed_response'
httparty (0.13.1) lib/httparty/response.rb:55:in `respond_to?'
fedex (3.6.1) lib/fedex/request/rate.rb:9:in `puts'
fedex (3.6.1) lib/fedex/request/rate.rb:9:in `puts'
fedex (3.6.1) lib/fedex/request/rate.rb:9:in `process_request'
fedex (3.6.1) lib/fedex/shipment.rb:39:in `rate'
app/models/order.rb:183:in `create_label'
app/controllers/orders_controller.rb:113:in `fedex_label'

Fedex::RateError (Fedex::RateError)

rate = fedex.rate(:shipper=>shipper,
:recipient => recipient,
:packages => packages,
:service_type => "FEDEX_GROUND",
:shipping_options => shipping_options
)

Creating label to print to Zebra thermal printer

I got the labels to create a full-size PDF, but it shows up distorted when printing to the ZP500 Thermal Printer to print FedEx labels. How can I create the labels in such a way that I can print to a thermal printer? When creating the label I have:

fedex.label( ..., :label_specifications => LABEL_SPECS )

LABEL_SPECS = { :label_format_type => "COMMON2D", :image_type => "ZPLII", :label_stock_type => "STOCK_4X6" }

I've gone through the FedEx API docs and tried any and all combinations for the label specs with no luck.

How to View PCX Files

This is not exactly an issue, but need some suggestions, as most people working with Fedex would require to print labels using thermal printers.

How do you usually view PCX file on your mac systems?

UPDATE
I worked on this and found to be very unproductive. Rather choose ZPLII for Lable Image and google how to view the now generated PCX file. Its much cleaner and productive.

Currency attribute is ignored in Rate

when making a rate request the currency attribute which is returned for all nodes with an amount (in ShipmentRateDetail) is ignored when the Rate object is created. Is there any reason that this is ignored?

Fedex v10 Reference

I'm trying to add some custom text content to my fedex labels, which I should be able to add via the label_specification element. However, the version of your gem I currently have is using v10 of their web services, and I'm having trouble finding their documentation for historical web services versions. Do you happen to know how to find versioned documentation from Fedex?

Thanks.

Fedex::RateError in New Tracking

I can get everything to work properly, but on new tracking numbers that haven't been scanned in yet i get a Fedex::RateError

Specifically, it says:
No information for the following shipments has been received by our system yet. Please try again or contact Customer Service at 1.800.Go.FedEx(R) 800.463.3339.

I guess I need to account for the error code? Is there a way to get it to return a nil value?

Address validation API not working - Fedex::RateError: Authentication Failed

Hi, sorry to bother you with this issue, but I am new to the Fedex world and I was requested to use this API for address validation.

I followed the examples, and while I can succesfully use other APIs (i.e. the rate API) the address validation doesn't work, it returns a Fedex::RateError: Authentication Failed error. Since credentials are the same I'm a bit frowned.
Any help would be appreciated ;-)

Andrea

How to set rate_request_type => 'RETAIL'

How to set rate_request_type => 'RETAIL'

We need the exact results from fedex . We checked in base.rb the rate_request_type is set to 'ACCOUNT', We checked by changing rate_request_type => 'RETAIL' , but it is sending the same result . And it is very diffrent than what fedex is showing .

Freight Rates

Excellent gem. Though one feature I'd like to see and one I plan on implementing myself is a rate request for Freight shipments. Before I dived in, I wanted to enquire if there were in caveats you guys came across in not implementing it?

After looking at the wsdl, the Fedex:::Request:::FreightRate code could easily be built.

Thoughts?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.