0 purchases
uni shipping
UniShipping #
Overview #
UniShipping is a Flutter package designed to integrate shipping functionalities into your e-commerce application or any system that requires coordination with shipping partners to dispatch products to customers. It simplifies the interaction with shipping APIs, making it easy to manage orders and shipments.
Features #
Initialize the package with your client credentials.
Create orders to be shipped to your customers.
Retrieve details of a single order.
Initiate the shipment process for an order.
Currently, UniShipping is tailored to work with the TOTROD shipping company, providing a streamlined way to handle logistics directly from your application.
Getting Started #
To use UniShipping in your Flutter project, follow these steps:
Installation #
Add UniShipping to your pubspec.yaml file:
dependencies:
uni_shipping: latest_version
copied to clipboard
Run flutter pub get to install the package.
Usage #
Import UniShipping in your Dart file:
import 'package:uni_shipping/uni_shipping.dart';
copied to clipboard
Initialize UniShipping with your client credentials and the environment setting:
void main() {
UniShippingConfigs.init(
clientId: 'YourClientId',
clientSecret: 'YourClientSecret',
environment: UniShippingEnvironment.staging,
);
runApp(const MyApp());
}
copied to clipboard
Create an Order
CreateOrderDTO createOrderBody = CreateOrderDTO(
// Your order details
);
CreateOrderRes createOrderRes = await UniShippingOrders.createOrder(createOrderBody);
copied to clipboard
Get Single Order
OrderModel singleOrder = await UniShippingOrders.getSingleOrder('YourOrderID');
copied to clipboard
Create Shipment Process
CreateshipmentDTO createShipProcessBody = CreateshipmentDTO(
// Your shipment details
);
ChipOrderResponse createShipProcessRes = await UniShippingShippment.createShipProcess(createShipProcessBody);
copied to clipboard
Example #
An example application demonstrating how to use UniShipping is included in the package. Check the example directory for more details.
Contributing #
Contributions are welcome! If you would like to contribute, please fork the repository and submit a pull request.
License #
UniShipping is available under the MIT license. See the LICENSE file for more info.
For personal and professional use. You cannot resell or redistribute these repositories in their original state.
There are no reviews.