Skip to main content

Prepare your package for shipment, manage returns, and cancel scheduled shipments.

Project description

UpsShipping Python SDK 1.0.0

Welcome to the UpsShipping SDK documentation. This guide will help you get started with integrating and using the UpsShipping SDK in your project.

Versions

  • SDK version: 1.0.0

About the API

Prepare your package for shipment, manage returns, and cancel scheduled shipments. In order to obtain your bearer token please follow the instructions at https://developer.ups.com/get-started, or use the UPS Authorization API.

Table of Contents

Setup & Configuration

Supported Language Versions

This SDK is compatible with the following versions: Python >= 3.7

Installation

To get started with the SDK, we recommend installing using pip:

pip install ups-shipping

Authentication

Access Token Authentication

The UpsShipping API uses an Access Token for authentication.

This token must be provided to authenticate your requests to the API.

Setting the Access Token

When you initialize the SDK, you can set the access token as follows:

UpsShipping(
    access_token="YOUR_ACCESS_TOKEN"
)

If you need to set or update the access token after initializing the SDK, you can use:

sdk.set_access_token("YOUR_ACCESS_TOKEN")

Using Union Types

Union types allow you to specify that a variable can have more than one type. This is particularly useful when a function can accept multiple types of inputs. The Union type hint is used for this purpose.

Example Function with Union Types

You can call service method with an instance of TypeA, TypeB, or a dictionary that can be converted to an instance of either type.

# Model Definition
ParamType = Union[TypeA, TypeB]

# Service Method
def service_method(param: ParamType):
...

## Usage
type_a = TypeA(key="value")
type_b = TypeB(key="value")

sdk.service.service_method(type_a)
sdk.service.service_method(type_b)
sdk.service.service_method({"key": "value"})

You cannot create an instance of a Union type itself. Instead, pass an instance of one of the types in the Union, or a dictionary that can be converted to one of those types.

Services

The SDK provides various services to interact with the API.

Below is a list of all available services with links to their detailed documentation:
Name
ShipmentsService
LabelsService

Models

The SDK includes several models that represent the data structures used in API requests and responses. These models help in organizing and managing the data efficiently.

Below is a list of all available models with links to their detailed documentation:
Name Description
ShipRequestWrapper
ShipResponseWrapper N/A
VoidshipmentResponseWrapper N/A
LabelrecoveryRequestWrapper N/A
LabelrecoveryResponseWrapper N/A
ShipmentRequest Shipment Request.
ShipmentRequestRequest Request Container
ShipmentRequestShipment Shipment Container
ShipmentRequestLabelSpecification Container used to define the properties required by the user to print and/or display the UPS shipping label. Required for shipment without return service or shipments with PRL return service. Required for Electronic Return Label or Electronic Import Control Label shipments with SubVersion greater than or equal to 1707.
ShipmentRequestReceiptSpecification Container used to allow the user to choose to print a thermal receipt.
RequestTransactionReference TransactionReference identifies transactions between client and server.
ShipmentReturnService Type of Return service. When this container exists, the shipment is a return shipment.
ShipmentShipper Container for the Shipper's information.
ShipmentShipTo Ship To Container.
ShipmentAlternateDeliveryAddress AlternateDeliveryAddress Container. Alternate Delivery Address (UPS Access Point Address) required if ShipmentIndicationType is 01 or 02.
ShipmentShipFrom Ship From Container. Required for return shipment. Required if pickup location is different from the shipper's address.
ShipmentPaymentInformation Payment information container for detailed shipment charges. The two shipment charges that are available for specification are Transportation charges and Duties and Taxes. It is required for non-Ground Freight Pricing shipments only.
ShipmentFrsPaymentInformation Container to hold the Payment information for the Ground Freight Pricing Shipments. Required for Ground Freight Pricing Shipments only.
ShipmentFreightShipmentInformation Container to hold Freight Shipment information.
ShipmentPromotionalDiscountInformation PromotionalDiscountInformation container. This container contains discount information that the customer wants to request each time while placing a shipment.
ShipmentDgSignatoryInfo DGSignatoryInfo Container DGPaperImage will be returned if DGSignatoryInfo container present
ShipmentShipmentRatingOptions ShipmentRatingOptions container.
ShipmentReferenceNumber Reference Number information container.
ShipmentService UPS service type.
ShipmentInvoiceLineTotal Container to hold InvoiceLineTotal Information. Required for forward shipments whose origin is the US and destination is Puerto Rico or Canada. Not available for any other shipments. FOR OTHER DESTINATIONS the InvoiceLineTotal in the International Forms Container must be used.
ShipmentShipmentIndicationType Container for Shipment Indication Type. Required to indicate whether shipment is "Hold For Pickup At UPS Access Point" for use by approved shippers to identify a UPS Access Point location as an alternate delivery option during shipment preparation or "UPS Access Point™ Delivery", ship parcels directly to a UPS Access Point location for collection by the receiver.
ShipmentShipmentServiceOptions Container for Shipment Service Options.
ShipmentPackage Package Information container. For Return Shipments up to and including 20 packages are allowed. US/PR origin return movements are limited to only one package. For Mail Innovations and Simple Rate shipments only one package is allowed.
ShipperPhone Container tag for Phone Number.
ShipperAddress Address tag Container. The package should be returned to this address if the package is undeliverable. This address appears on the upper left hand corner of the label. Note: If the ShipFrom container is not present then this address will be used as the ShipFrom address. If this address is used as the ShipFrom the shipment will be rated from this origin address.
ShipToPhone Container for Phone Number
ShipToAddress Address Container.
AlternateDeliveryAddressAddress Address Container.
ShipFromTaxIdType Tax Identification Container. Applies to EEI form only.
ShipFromPhone Container for Phone Number. If ShipFrom country or territory is US, PR, CA, and VI, the layout is: area code, 7 digit phone number or area code, 7 digit phone number, 4 digit extension number. For other countries or territories, the layout is: country or territory code, area code, 7 digit number. If ShipFrom tag is in the XML and International forms is requested.
ShipFromAddress Ship from Address Container. The package will be originating from or being shipped from this address. The shipment will be rated from this origin address to the destination ship to address.
ShipFromVendorInfo Vendor Information Container
PaymentInformationShipmentCharge Shipment charge container. If Duty and Tax charges are applicable to a shipment and a payer is not specified, the default payer of Duty and Tax charges is Bill to Receiver. There will be no default payer of Duty and Tax charges for DDU and DDP service.
ShipmentChargeBillShipper Container for the BillShipper billing option. The three payment methods that are available for the Bill Shipper billing option are alternate payment method, account number or credit card. This element or its sibling element, BillReceiver, BillThirdParty or ConsigneeBilledIndicator, must be present but no more than one can be present.
ShipmentChargeBillReceiver Container for the BillReceiver billing option. This element or its sibling element, BillShipper, BillThirdParty or Consignee Billed, must be present but no more than one can be present. For a return shipment, Bill Receiver is invalid for Transportation charges.
ShipmentChargeBillThirdParty Container for the third party billing option. This element or its sibling element, BillShipper, BillReceiver or Consignee Billed, must be present but no more than one can be present.
BillShipperCreditCard Credit card information container. Required if neither of the following is present: /ShipmentRequest/Shipment/PaymentInformation/ShipmentCharge/BillShipper/AccountNumber or /ShipmentRequest/Shipment/PaymentInformation/ShipmentCharge/BillShipper/AlternatePaymentMethod. Credit card payment is valid for shipments without return service only.
CreditCardAddress Container to hold the Credit card Billing Address. It is required to provide billing address if credit card information is provided and when the ShipFrom country or territory is the US, PR, and CA.
BillReceiverAddress Container for additional information for the bill receiver's UPS accounts address.
BillThirdPartyAddress Container for additional information for the third party UPS accounts address.
FrsPaymentInformationType Container to hold the Ground Freight Pricing payment type information. It is required if the request has Ground Freight Pricing shipment indicator.
FrsPaymentInformationAddress Container to hold the information for the FreightCollect and PrepaidThirdParty Address. Note: The Address is required only when the billing option is Freight collect or ThirdParty.
FreightShipmentInformationFreightDensityInfo Freight Density Info container. Required if DensityEligibleIndicator is present.
FreightDensityInfoAdjustedHeight Container for the adjusted height. Required if AdjustedHeightIndicator is present.
FreightDensityInfoHandlingUnits Handling Unit for Density based rating container.
AdjustedHeightUnitOfMeasurement Container for UnitOfMeasurement for the adjusted height.
HandlingUnitsType Handling Unit Type for Density based rating.
HandlingUnitsDimensions Dimension of the HandlingUnit container for density based pricing.
HandlingUnitsUnitOfMeasurement UnitOfMeasurement container.
ShipmentServiceOptionsCod COD container Indicates COD is requested. Shipment COD is only available for EU origin countries or territories and for shippers account type Daily Pickup and Drop Shipping. Not available to shipment with return service.
ShipmentServiceOptionsAccessPointCod Access Point COD indicates COD is requested for a shipment. Valid only for "01 - Hold For Pickup At UPS Access Point" Shipment Indication type. Shipment Access Point COD is valid only for countries or territories within E.U. Not valid with (Shipment) COD. Not available to shipment with return service.
ShipmentServiceOptionsNotification Container for the Quantum View Notification (QVN) is valid for all shipments including Return service, Import Control and Returns Flexible Access. Valid return service types are: ERL, PRL, PNM, RS1, or RS3. The shipment level notification is valid for forward and return international shipments as well as for domestic shipments (for US and PR).
ShipmentServiceOptionsLabelDelivery Container for the Label Delivery accessorial. Note - LabelDelivery is not applicable for GFP and Mail Innovations Forward shipment. Required for shipments with either Electronic Return Label Return Service or ImportControl Electronic LabelMethod type. Optional for shipments with Print Return Label Return Service or ImportControl Print LabelMethod type or Forward movement. If this container is present for shipments with either Electronic Return Label Return Service or ImportControl Electronic LabelMethod type, either of the LabelLinksIndicator or EMail container should be provided. For shipments with Print Return Label Return Service or ImportControl Print LabelMethod type or Forward movement, only LabelLinksIndicator is valid option for LabelDelivery container.
ShipmentServiceOptionsInternationalForms International Forms information.
ShipmentServiceOptionsDeliveryConfirmation Delivery Confirmation container. Valid for forward shipments only. Refer to Delivery Confirmation Origin-Destination Pairs in the Appendix for a list of valid values.
ShipmentServiceOptionsLabelMethod Type of ImportControl Label. This container is applicable only for ImportControl shipments. This container is applicable only for ImportControl shipments.
ShipmentServiceOptionsPreAlertNotification This container is used for providing Pre-Alert Notifications to the consignee for UPS Exchange movements and Pack & Collect shipments.
ShipmentServiceOptionsRestrictedArticles Restricted Articles container.
CodCodAmount COD Amount container.
NotificationEMail Container for Email Information.
NotificationVoiceMessage VoiceMessage container is used for specifying phone number for receiving voice Alternate Delivery Location notification and UAP Shipper notification. Valid only for Alternate Delivery Location notification and UAP Shipper notification. VoiceMessage phone number or TextMessage phone number or email address is required for ADL notification and UAP Shipper notification.
NotificationTextMessage TextMessage container is used for specifying phone number for receiving text Alternate Delivery Location notification and UAP Shipper notification. Valid only for Alternate Delivery Location notification and UAP Shipper notification. VoiceMessage phone number or TextMessage phone number or email address is required for ADL notification and UAP Shipper notification.
NotificationLocale This container is used for providing Language and dialect details for Alternate Delivery Location notifications and UAP Shipper notifications. Valid only for Alternate Delivery Location notification and UAP Shipper notification.
LabelDeliveryEMail Container for the email message.
InternationalFormsUserCreatedForm Data container for DocumentID(s). Required if Form Type is 07.
InternationalFormsUpsPremiumCareForm UPS Premium Care Form is required if UPS Premium Care Indicator is present on a package. Valid only for Canada to Canada movements.
InternationalFormsCn22Form Container for the CN22 form. Required if the customer wants to use the UPS generated CN22.
InternationalFormsEeiFilingOption EEI Filing option. Applicable for EEI form and is required.
InternationalFormsContacts Holds the contact information of various parties. Applicable for EEI and NAFTA CO only. Required for NAFTA CO and EEI. Ultimate consignee contact information is required for EEI. Producer contact information is required for NAFTA CO
InternationalFormsProduct Contains the commodity/product information. Applies to EEI, Invoice, Partial Invoice, CO and NAFTA CO. When any International form is requested, at least one Product must be present. Maximum number of products allowed for different forms are: 50: Package Packing List 100: Commercial Invoice, NAFTA, CO, EEI 1000: Air Freight packing list Note: For Partial Invoice this container is optional.
InternationalFormsDiscount Container tag that holds the discount. Applies to Invoice and Partial Invoice forms only.
InternationalFormsFreightCharges Container tag that holds the Freight Charges. Applies to Invoice and Partial Invoice forms only.
InternationalFormsInsuranceCharges Container tag that holds the Insurance Charges. Applies to Invoice and Partial Invoice forms only.
InternationalFormsOtherCharges Container tag that holds the information of amount that covers additional charges not already listed on the invoice. Applies to Invoice and Partial Invoice forms only.
InternationalFormsBlanketPeriod This field should be entered if the NAFTA Certificate covers multiple shipments of identical goods as described in the Description of Goods field that are imported into a NAFTA country or territory for a specified period of up to one year (the blanket period). The importation of a good for which preferential treatment is claimed based on this certificate must occur between these dates. Applies to NAFTA CO form only. Required for NAFTA CO. This is not valid for a paperless shipment.
UpsPremiumCareFormLanguageForUpsPremiumCare Container to hold languages in which UPS Premium Care Form is required.
Cn22FormCn22Content Container for CN22 content. Required if the CN22 form container is present. Note: The maximum number of goods printed on the CN22 form when a combined MI package and CN22 form label is requested is 30.
Cn22ContentCn22ContentWeight Container for CN22 content weight.
Cn22ContentWeightUnitOfMeasurement Container for UOM.
EeiFilingOptionUpsFiled Indicates the EEI UPS Filed option. (option 3) Applicable for EEI form.
EeiFilingOptionShipperFiled Indicates the EEI Shipper Filed option or AES Direct. (Option 1 or 2). Applicable for EEI form.
UpsFiledPoa Container for POA. Applicable for EEI form.
ContactsForwardAgent The forwarding agent is the company or person acting as agent in the trans-shipping of freight to the destination country or territory. Applicable for EEI form only.
ContactsUltimateConsignee The ultimate consignee is the person or company who receives the goods for end-use or the person or company listed on the export license. This is the end-user of the goods. Applicable for EEI form only.
ContactsIntermediateConsignee The intermediate consignee is the person or company in the importing country or territory that makes final delivery to the ultimate consignee. Applicable for EEI form only.
ContactsProducer Information of the producer. The NAFTA Certificate of Origin must be completed, signed, and dated by the exporter. When the Certificate is completed by the producer for use by the exporter, it must be completed, signed, and dated by the producer. The date must be the date the Certificate was completed and signed. Applies to NAFTA CO. Required for NAFTA CO forms.
ContactsSoldTo SoldTo Container. The Sold To party's country code must be the same as the Ship To party's country code with the exception of Canada and satellite countries. Applies to Invoice and NAFTA CO Forms. Required if Invoice or NAFTA CO (International Form) is requested.
ForwardAgentAddress Address information of the Forwarding agent. Applicable for EEI form only.
UltimateConsigneeAddress Address information of the Ultimate consignee. Applicable for EEI form only.
UltimateConsigneeUltimateConsigneeType Container for providing UltimateConsignee Type. Applicable for EEI form only.
IntermediateConsigneeAddress Address information of the Intermediate Consignee. Applicable for EEI form only.
ProducerAddress Address information of the Producer. Applies to NAFTA CO. Only applicable if producer option is empty or not present. Conditionally required for: NAFTA CO, when Producer option is not specified.
ProducerPhone Phone number information of Producer. Applies to NAFTA CO.
SoldToPhone Phone Container.
SoldToAddress Sold To Address Container. Applies to NAFTA CO.
ProductUnit Container tag for the Unit information of each product. (also called as commodity) Required for Invoice forms and optional for Partial Invoice.
ProductNetCostDateRange Date Range for regional value content (RVC). Applies to NAFTA CO only.
ProductProductWeight The shipping weight, including containers, for each commodity with a separate Harmonized Tariff Code / Schedule B Number. This weight does not include carrier equipment. Applies to CO and EEI forms only. Required for CO and EEI forms.
ProductScheduleB Container tag for the schedule B information of a commodity. Applies to EEI forms only. Required for EEI form
ProductExcludeFromForm Container tag for determining whether or not to exclude product information from a particular form. If this container is not present we assume that the DEFAULT is selected which is "none" and all products will appear on all forms.
ProductPackingListInfo Data Container holding package related information. Required for packaging list and Air Freight Packing list.
ProductEeiInformation Required for EEI form. Applies to EEI form only.
UnitUnitOfMeasurement Container tag for the Unit of measurement for the commodity. Required for Invoice forms and optional for Partial Invoice.
ProductWeightUnitOfMeasurement Container tag for the Unit of Measurement of weight. Applies to CO and EEI forms only.
ScheduleBUnitOfMeasurement The unit of measure indicated on the Export License. Applies to EEI forms only.
PackingListInfoPackageAssociated Data Container holding package/product related information that will break up the product into each package on the packing list. Total product amount must equal the product unit value above. Required for packaging list and Air Freight Packing list. Packaging list max allowed : 20 Air Freight Packaging list max allowed: 200
EeiInformationLicense Licence information for SDL commodity. Applies to EEI form only.
EeiInformationDdtcInformation Department of State/ Directorate of Defense Trade Control Information. This element is a container for additional information that is applicable to SDL products. It will only be evaluated if the provided license code is an SDL code. Applies to EEI Form only.
DdtcInformationUnitOfMeasurement Container for unit of measurement. Applies to EEI form only. It is required for EEIFilingOption code 3.
PreAlertNotificationEMailMessage This container is used for Populating EMailMessage details for PreAlertNotification.
PreAlertNotificationVoiceMessage VoiceMessage container is used for specifying phone number for receiving voice PreAlertNotification.
PreAlertNotificationTextMessage TextMessage container is used for specifying phone number for receiving text preAlertNotification.
PreAlertNotificationLocale This container is used for providing Language and dialect details for PreAlertNotification.
PackagePackaging Packaging container. Container for Packaging Type.
PackageDimensions Dimensions information container. Note: Currently dimensions are not applicable to Ground Freight Pricing. Length + 2*(Width + Height) must be less than or equal to 165 IN or 330 CM. Required for Heavy Goods service. Package Dimension will be ignored for Simple Rate
PackageDimWeight Dimensional weight of shipment. Please visit ups.com for rules on calculating. There is one implied decimal place (e.g. 115 = 11.5). If dimensions are provided, dimensional weight is ignored. For US/PR/CA shipments, dimensional weight is ignored
PackagePackageWeight Container to hold package weight information. Package weight is a required for Ground Freight Pricing shipments and Heavy Goods service. Package Weight will be ignored for Simple Rate.
PackageReferenceNumber Package reference number information container. For Mail Innovation shipments, up to 3 reference numbers are supported. If 5 reference numbers are specified (CostCenter, PackageID, and 3 ReferenceNumbers) the 3 desigated by the ReferenceNumber container will not be visible on 4x6 label supported by the API. These additional reference numbers are only be visible on the 4x8 label.. For non-Mail Innovation shipments only the first 2 reference numbers will be visible on labels.
PackageSimpleRate SimpleRate Container
PackageUpsPremier UPS Premier Container.
PackagePackageServiceOptions Package Service Options container.
PackageCommodity Container to hold the Commodity information. It is required if the Ground Freight Pricing Shipment indicator is present in the request.
PackageHazMatPackageInformation Required when number of hazmat containers in a package is greater than 1. It indicates whether all the hazmat materials are kept in a single box or multiple boxes. Required when number of hazmat container in a package is greater than 1.
DimensionsUnitOfMeasurement UnitOfMeasurement container for dimensions.
DimWeightUnitOfMeasurement UnitOfMeasurement Container.
PackageWeightUnitOfMeasurement Container to hold UnitOfMeasurement information for package weight.
UpsPremierHandlingInstructions Handling Instruction Container.
PackageServiceOptionsDeliveryConfirmation Delivery Confirmation container. Refer to Delivery Confirmation Origin- Destination Pairs in the Appendix for a list of valid values. Valid only for forward shipment only.
PackageServiceOptionsDeclaredValue Container for Declared Value.
PackageServiceOptionsCod Container for COD. Indicates COD is requested. Package level COD is available for shipment without return service from US/PR to US/PR, CA to CA, and CA to US. CA to US COD is not allowed for package Letter/ Envelope. COD is not valid for return service movements.
PackageServiceOptionsAccessPointCod Access Point COD indicates Package COD is requested for a shipment. Valid only for "01 - Hold For Pickup At UPS Access Point" Shipment Indication type. Package Access Point COD is valid only for shipment without return service from US/PR to US/PR and CA to CA. Not valid with COD at package level.
PackageServiceOptionsNotification Receiver Return Notification. Applicable for Shipment with returned service.
PackageServiceOptionsHazMat Container to hold HazMat Chemical Records.
PackageServiceOptionsDryIce Container for Dry Ice. Maximum 1 Dry Ice is allowed. Lane check will happen based on postal code/ city.
DeclaredValueType Container for Declared Value Type.
PackageServiceOptionsCodCodAmount COD Amount container.
PackageServiceOptionsNotificationEMail Container for the e-mail message.
DryIceDryIceWeight Container for Dry Ice weight.
DryIceWeightUnitOfMeasurement Container for Unit of measurement for Dry Ice Weight.
CommodityNmfc Container to hold the NMFC codes.
LabelSpecificationLabelImageFormat LabelImageFormat Container.
LabelSpecificationLabelStockSize Container for the EPL2, ZPL or SPL label size. Valid for EPL2, ZPL and SPL Labels.
LabelSpecificationInstruction Routing Instruction Container.
ReceiptSpecificationImageFormat ImageFormat Container.
ShipmentResponse Shipment Response.
ShipmentResponseResponse Response container for Shipment response.
ShipmentResponseShipmentResults Shipment Results container.
ResponseResponseStatus Response status container.
ResponseAlert Alert Container. There can be zero to many alert containers with code and description.
ResponseTransactionReference Transaction Reference Container.
ShipmentResultsDisclaimer
ShipmentResultsShipmentCharges Shipment charges Container. Shipment charges info.
ShipmentResultsNegotiatedRateCharges Negotiated Rates Charge Container. For tiered rates and promotional discounts, if a particular shipment based on zone, origin, destination or even shipment size doesn't qualify for the existing discount then no negotiated rates container will be returned. Published rates will be the applicable rate.
ShipmentResultsFrsShipmentData Ground Freight Pricing Shipment data container. Ground Freight Pricing shipment data is only guaranteed to be returned for Ground Freight Pricing shipments only.
ShipmentResultsBillingWeight Billing Weight container.
ShipmentResultsPackageResults
ShipmentResultsControlLogReceipt
ShipmentResultsForm Container tag for the International forms image. Form is returned for following shipments - Forward shipments, Shipments with PRL ReturnService, Electronic Return Label or Electronic Import Control Label shipments with SubVersion greater than or equal to 1707.
ShipmentResultsCodTurnInPage The container of the COD Turn In Page.
ShipmentResultsHighValueReport Container for the High Value Report generated for ImportControl or Return shipments with high package declared value.
ShipmentChargesBaseServiceCharge Base Service Charge container. Transportation charge = BaseServiceCharge + Fuel charge Returned only if Subversion >=1701.
ShipmentChargesTransportationCharges Transportation Charges container.
ShipmentChargesItemizedCharges
ShipmentChargesServiceOptionsCharges Service Option Charges container.
ShipmentChargesTaxCharges
ShipmentChargesTotalCharges Total charges container.
ShipmentChargesTotalChargesWithTaxes TotalChargesWithTaxes container would be returned only if TaxInformationIndicator is present in request and when Negotiated Rates are not applicable. TotalChargesWithTaxes contains total charges including total taxes applied to a shipment.
NegotiatedRateChargesItemizedCharges
NegotiatedRateChargesTaxCharges
NegotiatedRateChargesTotalCharge Total charges container. Account Based Rates info. Total charges are only returned for ABR eligible shipper account/UserId combinations when the user includes the NegotiatedRatesIndicator in the request.
NegotiatedRateChargesTotalChargesWithTaxes TotalChargesWithTaxes container would be returned only if TaxInformationIndicator is present in request. TotalChargesWithTaxes contains total charges including total taxes applied to a shipment.
FrsShipmentDataTransportationCharges Transportation charges container. Ground Freight Pricing transportation charges. These are only returned for Ground Freight Pricing enabled shipper account number when the user includes the FRSShipmentIndicator in the request.
FrsShipmentDataFreightDensityRate FreightDensityRate container for Density based rating.
FrsShipmentDataHandlingUnits
TransportationChargesGrossCharge Gross Charges container. It indicates the shipment level gross Ground Freight Pricing transportation charges.
TransportationChargesDiscountAmount Discount Amount container. It indicates the shipment level Ground Freight Pricing discount amount for transportation charges
TransportationChargesNetCharge Net Charges container. It indicates the shipment level net Ground Freight Pricing transportation charges.
HandlingUnitsAdjustedHeight Container to hold Adjusted Height information.
BillingWeightUnitOfMeasurement Billing weight unit of measurement code. The unit of measurement used in Shipment request is returned.
PackageResultsRateModifier Container for returned Rate Modifier information. Applies only if SubVersion is 2205 or greater.
PackageResultsBaseServiceCharge Base Service Charge container. Transportation charge = BaseServiceCharge + Fuel charge Returned only if Subversion >=1701.
PackageResultsServiceOptionsCharges Shipment charges info. Shipment charges are only guaranteed to be returned for shipments whose origin country or territory is US or Puerto Rico.
PackageResultsShippingLabel The container for UPS shipping label. Returned for following shipments - Forward shipments, Shipments with PRL returns service, Electronic Return Label or Electronic Import Control Label shipments with SubVersion greater than or equal to 1707. Shipping label wont be returned if BarCodeImageIndicator is present.
PackageResultsShippingReceipt Supported for following shipments - PRL shipments, Electronic Return Label or Electronic Import Control Label shipments with SubVersion greater than or equal to 1707.
PackageResultsAccessorial
PackageResultsSimpleRate SimpleRate will be returned if Simple Rate present in request
PackageResultsForm Container tag for the International forms image. Currently this container would be returned for UPS Premium Care shipments. Form is returned for following shipments - Forward shipments, Shipments with PRL ReturnService, Electronic Return Label or Electronic Import Control Label shipments with SubVersion greater than or equal to 1707. CN22 data for Worlwide economy services will be returned within the PDF417 barcode of the label.
PackageResultsItemizedCharges
PackageResultsNegotiatedCharges Negotiated Rates Charge Container. These charges are returned when: 1) Subversion is greater than or equal to 1607 2) If negotiated rates were requested for GFP shipments and account number is eligible to receive negotiated rates.
ShippingLabelImageFormat The container image format.
ShippingReceiptImageFormat Container for a Image Format.
FormImage Container tag for the International forms image.
ImageImageFormat Container tag for the International forms image format information.
NegotiatedChargesItemizedCharges
ControlLogReceiptImageFormat Container for the High Value report format required if parent exist.
ShipmentResultsFormImage Container tag for the International forms image.
ShipmentResultsImageImageFormat Container tag for the International forms image format information.
CodTurnInPageImage The container of the image for COD Turn In Page.
CodTurnInPageImageImageFormat The container for format of COD Turn In Page.
HighValueReportImage Container tag for the High Value Report image.
HighValueReportImageImageFormat Container for the High Value Report image format information for Import Control Shipments.
VoidShipmentResponse Void Response Container.
VoidShipmentResponseResponse Response Container.
VoidShipmentResponseSummaryResult Container for the Summary Result
VoidShipmentResponsePackageLevelResult
VoidResponseResponseStatus Response Status Container.
VoidResponseTransactionReference Transaction Reference Container.
SummaryResultStatus Container for the status of the Summary Result
PackageLevelResultStatus Contains the status code tags.
LabelRecoveryRequest Request for obtaining the Label for the return shipment.
LabelRecoveryRequestRequest Request Container.
LabelRecoveryRequestLabelSpecification Container that is used to define the properties required by the user to print and/ or display the UPS shipping label. Required for the shipment without return service, or shipment with PRL return service.
LabelRecoveryRequestTranslate Translate container allows the user to specify the language he/she would like a specific portion of response to return. The language is specified by the combination of language code and dialect code. Valid combinations are: LanguageCode + DialectCode. Either Translate container or Locale element can be present in a given request. Both can't be requested together in same request. Combinations: eng GB = Queen's English Spa 97 = Castilian Spanish ita 97 = Italian fra 97 = France French fra CA = Canadian French deu 97 = German por 97 = Portugal Portuguese nld 97 = Dutch dan 97 = Danish fin 97 = Finnish swe 97 = Swedish eng CA = Canadian English Eng US = US English Default language is Queen's English If the Ship from country or territory is Canada, the Language defaults to Canadian English. If the ship from country or territory is US, the language defaults to US English. If shipping from some other country or territory, the language defaults to Queens English.
LabelRecoveryRequestLabelDelivery Container for the Label Delivery accessorial. One Label Delivery per shipment.
LabelRecoveryRequestReferenceValues Container that holds reference number and shipper number If tracking number is not present use reference Number
LabelRecoveryRequestUpsPremiumCareForm UPS Premium Care Form container. Default is PDF when container is not provided. Valid only for Canada to Canada movements. UPS Premium Care Form will be returned in both US English and Canadian French language.
LrRequestTransactionReference Container that identifies transactions between client and server.
LabelRecoveryLabelSpecificationLabelImageFormat The file format of the label and receipt. Defaults to HTML format if this node does not exist.
LabelRecoveryLabelSpecificationLabelStockSize Container to hold Label Height and Width information. Applicable if Label Image Code is ZPL, EPL and SPL. Ignored for other Label Image Code types.
ReferenceValuesReferenceNumber Container for reference number
LabelRecoveryResponse Response for the Label recovery request Validates the date range and label being present. Also if the shipment is return or not
LabelRecoveryResponseResponse Response Container
LabelRecoveryResponseCodTurnInPage Container for COD Turnin Page.
LabelRecoveryResponseForm Container tag for the International Forms. Currently, represents Commercial Invoice for Electronic Returns Label and Electronic Import Control Label. Applicable for Electronic Return Label and Electronic Import Control Label shipments only. Returned for request with SubVersion greater than or equal to 1707.
LabelRecoveryResponseHighValueReport Container tag for the High Value Report for Electronic Returns Label and Electronic Import Control Label. Applicable for Electronic Return Label and Electronic Import Control Label shipments only. Returned for request with SubVersion greater than or equal to 1707.
LrResponseResponseStatus Response Status container
LrResponseTransactionReference Transaction Reference Container
LabelRecoveryResponseLabelResults Container that stores the label results. Information containing the results of the user's Label Recovery Request.
LabelResultsLabelImage The elements needed to render a label on a printer or in a browser. Specifies the format in which GraphicImage is represented. If LabelImageFormat is GIF, LabelImage contains GraphicImage and HTMLImage. Otherwise, it contains only GraphicImage. If LabelImageFormat is PDF, LabelImage is only returned at the first package result. If entered in the request, the response mirrors, else the default values are returned. Returned only if TrackingNumber or Combination of Reference Number and Shipper Number present in request.
LabelResultsMailInnovationsLabelImage Container to hold Mail Innovations shipments label. The elements needed to render a label on a printer or in a browser. Specifies the format in which GraphicImage is represented. If LabelImageFormat is GIF, LabelImage contains GraphicImage and HTMLImage. Otherwise, it contains only GraphicImage. Applicable for Single Mail Innovations Returns and Dual Mail Innovations Returns shipment. Returned only if MailInnovationsTrackingNumber is provided in request. If LabelImageFormat requested was PDF and TrackingNumber was present along with MailInnovationsTrackingNumber in the request, only LabelImage container is returned. MailInnovationsLabelImage will not be returned. In that case, the labels for Small Package Tracking Number and Mail Innovations Tracking Number will be stitched in single PDF file.
LabelResultsReceipt Container for the HTML receipt and the receipt link.
LabelResultsForm Container tag for the International Forms. Currently, represents UPS Premium Care Form for Electronic Returns Label and Electronic Import Control Label. UPS Premium Care Form for Forward shipment if Subverion is 1903 or greater Applicable for Electronic Return Label and Electronic Import Control Label shipments only. Applies only for Canada domestic shipments. Returned for request with SubVersion greater than or equal to 1707. UPS Premium Care Form for Forward shipment if Subverion is 1903 or greater
LabelImageLabelImageFormat The format of a label image byte stream.
MailInnovationsLabelImageLabelImageFormat The format of a label image byte stream.
ReceiptImage Container for the receipt in the format other than HTML.
ReceiptImageImageFormat Container for the format of the receipt.
LrFormImage Container tag for the International Forms image.
LrcodTurnInPageImage Container for COD Turnin Page Image.
LrCodTurnInPageImageImageFormat Container for the format of image.
LabelRecoveryFormImage Container tag for the International Forms image.
LabelRecoveryImageImageFormat Container tag for the International forms image format information.
LabelRecoveryResponseTrackingCandidate Information containing the results of the users Label Recovery Request. Returned in the event the Shipper Number and Reference Number are supplied in the request.
TrackingCandidatePickupDateRange A range of time the package was picked up.

License

This SDK is licensed under the MIT License.

See the LICENSE file for more details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ups-shipping-1.0.0.tar.gz (156.3 kB view details)

Uploaded Source

Built Distribution

ups_shipping-1.0.0-py3-none-any.whl (263.0 kB view details)

Uploaded Python 3

File details

Details for the file ups-shipping-1.0.0.tar.gz.

File metadata

  • Download URL: ups-shipping-1.0.0.tar.gz
  • Upload date:
  • Size: 156.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.7.17

File hashes

Hashes for ups-shipping-1.0.0.tar.gz
Algorithm Hash digest
SHA256 894bae5b706e54707f499c6eaa636219fd78a2165da71939d3e63b6173bd907e
MD5 8f89e202757b907a9f7da066dab9156f
BLAKE2b-256 5de120db7ea9f6eef8aced5246a6d5e80823179206bf7cba15cce8a8352b7b85

See more details on using hashes here.

File details

Details for the file ups_shipping-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: ups_shipping-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 263.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.7.17

File hashes

Hashes for ups_shipping-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b379fbb46b7b4f6f2d82789d7ddc001fb172873b26999a4c9fbeacf53302928b
MD5 3a5f51e500c0ad55b67e4e3a5351011b
BLAKE2b-256 1d36ad47dd3b80486bfb1414a8bdbc1cc6eaf3f16966629987f38b5f122400d5

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page