v3.0.0
What's Changed
- Drop support for Go 1.15
- Minimum supported version is now Go 1.16
- Adds specific error types for API and local errors
- All errors inherit the
LibraryError
interface- API errors inherit the
APIError
interface, which inherits theLibraryError
interface - Local errors inherit the
LocalError
interface, which inherits theLibraryError
interface
- API errors inherit the
- Common error messages are now available as constants for parsing (e.g. regex)
- All errors inherit the
- All uses of
*time.Time
have been replaced with neweasypost.DateTime
classDateTime
is a wrapper aroundtime.Time
that handles unexpected date formats from the API
- Previously-marked deprecated functions and structs have been removed:
ListReportOptions
struct -> useListOptions
struct instead- Beta carrier metadata functions -> use non-beta functions instead
LowestRate
shipment functions -> useLowestShipmentRate
functions insteadCreateWebhook
function -> useCreateWebhookWithDetails
function insteadEnableWebhook
function -> useUpdateWebhook
function instead
TrackingCodes
string array onListTrackersOptions
struct is nowTrackingCode
single stringAddShipmentsToBatch
andRemoveShipmentsFromBatch
functions now explicitly acceptShipment
structs instead of genericinterface{}
types- Functions will no longer accept solely IDs; users will need to provide whole
Shipment
structs
- Functions will no longer accept solely IDs; users will need to provide whole
Please view our Upgrade Guide for details on how to upgrade from 2.x to 3.0.
Full Changelog: v2.20.0...v3.0.0