v6.0.0
Includes all the changes from v6.0.0-rc1 listed below in addition to the following:
- All constants are now defined in the top-level 
Constantsclass (com.easypost.Constants)- Users who are utilizing the constants for exception message parsing should account for the new namespace
 
 - Added support for creating/registering carrier accounts that require custom workflows (e.g. FedEx, UPS)
 - Swapped the parameters for the following functions, making 
idthe first argumentShipment.generateForm()EndShipper.update()CarrierAccount.update()
 - Fixed a typo, 
ServiceUnavailablErroris nowServiceUnavailableError - Fixed a typo: 
Smartrateis nowSmartRate,apikeysis nowapiKey,scanformis nowscanForm - Moved 
validateWebook,findLowestSmartrate, andgetLowestSmartRatefrom Services to Utilities since it does not required an EasyPost client object - Added a root level 
APIExceptionclass for all HTTP exceptions 
Breaking Changes
- Library is now thread-safe
- Initialize an 
EasyPostClientobject with an API key. Optionally set connection and readtime params - All methods (i.e. 
create,retrieve,all) exist in services, accessed via property of the client (eg:client.shipment.create())- E.g. Static method -> 
Shipment shipment = client.address.create(params) - E.g. Instance methods are now static -> 
Shipment boughtShipment = client.shipment.buy(shipmentID, lowestRate) 
 - E.g. Static method -> 
 - All functions are now taking object ID instead of an object, which means the functions are returning the response value directly instead of updating the current object
- E.g. 
Shipment boughtShipment = client.shipment.buy(shipmentID, lowestRate) 
 - E.g. 
 
 - Initialize an 
 - Improves error exception handling
- Specific error types for each category of error
 - API error message may be an array rather than a string. Arrays will be concatenated (by comma) and returned as a string.
 
 - Removes 
createAndVerifyWithCarrierfunction - Removes 
verifyWithCarrierfunction - Removes 
getUpdateandsetUpdatefrom Tracker class - Removes all beta features and corrsponding unit tests
 - Removes 
serviceCodefromRateclass since this value is internal use only - Removes invalid function 
User.create()since creating a child-user requires a name - Removes deprecated class 
CreditCardand its associated classesPrimaryPaymentMethod,SecondaryPaymentMethod, andBaseCreditCard, please use alternativeBillingclass - Removes all the setters of each object
 - Removes the 
refresh()function in all classes, please useretrieve()function instead - Removes invalid functions that allow users to make an API request without providing required parameters
 - Changes the type of Insurance 
Amountfrom Float to String - Changes the type 
hasMorein ReferralCustomerCollection frombooleantoBoolean - Renames some getters
- Pickup class: 
getPickoutRates()->getPickupRates() - PaymentMethod class: 
getPrimaryPaymentMethodObject()->getPrimaryPaymentMethod() - PaymentMethod class: 
getSecondaryPaymentMethodObject()->getSecondaryPaymentMethod() 
 - Pickup class: 
 - Converts return type from a boolean to void when we receive an empty response body from the API
fundWallet()anddeletePaymentMethod()in Billing classcreateList()in Tracker classupdateEmail()in ReferralCustomer class
 - Changes the type 
resultof Event fromEasyPostResourcetoMap<String, Object> 
Bug Fixes
- Adds two missing attributes in the Event class: 
pendingUrlsandcompletedUrls - AppEngine default timeout is now the same as connection timeout