Crate intrac

Crate intrac 

Source
Expand description

§Intrac

This is an unofficial tiny API client for Easypack24 v1 (InPost delivery services) that helps you track locker-to-locker deliveries of parcels on the aforementioned platforms.

The API endpoints used are public and don’t require authentication at the time of writing. The full API docs are available at InPost Italy Developers

§Example

use intrac::InPostApiClient;
 
pub async fn print_shipment_status(shipment_id: &str /* 0123...888 */) -> Result<(), Box<dyn std::error::Error>> {
    let mut api_client = InPostApiClient::new("it" /* country code */)?;
    let shipment = api_client.lookup_shipment(shipment_id).await?;
    println!("Status: {}", shipment.status);
    Ok(())
}

§Unimplemented features

  • Authenticated requests: label creation, shipment creation, query by company
  • Points list
  • expected_flow in Shipment
  • location in TrackingEvent

Structs§

CustomAttributes
Information regarding the source/target locker machines and collection times of a Shipment.
GeoAddress
Represents a postal address.
Geolocation
Represents a set of geographic coordinates.
InPostApiClient
This is an API client that provides access to the InPost services over HTTP. It enforces HTTPS and doesn’t send any extra headers.
MachineDetail
Information on a specific parcel locker machine.
Shipment
An existing parcel shipment in the Easypack24 APIs.
TrackingEvent
Represents an entry in the event log of a Shipment.

Enums§

MachineType
The only known value at the moment is parcel_locker, self-explanatory.