pyusps icon indicating copy to clipboard operation
pyusps copied to clipboard

Optional Response Params need a "Revision" XML tag

Open prabhathn opened this issue 5 years ago • 2 comments

Propose adding this at the following line: https://github.com/thelinuxkid/pyusps/blob/master/pyusps/address_information.py#L133

    # Documentation refers to this as "Version" - it is an option to return all optional data as well
    version_el = etree.Element('Revision')
    version_el.text = '1'
    root.append(version_el)
    

Without this code, the USPS API only returns the Address, City, State, Zip. By including this Revision tag, we get all the optional params as well.

prabhathn avatar Oct 17 '19 06:10 prabhathn

Thanks. Can you make a PR please?

thelinuxkid avatar Oct 18 '19 17:10 thelinuxkid

Sure! Here you go: https://github.com/thelinuxkid/pyusps/pull/8

Thanks!

prabhathn avatar Oct 21 '19 23:10 prabhathn