ShipEngine / shipengine-java

The official Java SDK for ShipEngine API
https://www.shipengine.com/docs/
Apache License 2.0
1 stars 1 forks source link
address-validation api dhl-api fedex-api java jdk package-tracking rest-api sdk shipengine shipment-tracking shipping-api shipping-label shipping-rates tracking-number ups-api usps-api

ShipEngine

ShipEngine Java SDK

The official Java SDK for ShipEngine API.

GitHub Workflow Status (branch) Coverage Status GitHub OS Compatibility

Quick Start

Install shipengine from the Maven Central Repository by adding the following under the dependencies key in your pom.xml:

<dependency>
    <groupId>com.shipengine</groupId>
    <artifactId>shipengine</artifactId>
    <version>1.0.1</version>
</dependency>

Instantiate ShipEngine Class

import com.shipengine.ShipEngine;

public class ShipEngineDemo {
    public static void main() {
        ShipEngine shipengine = new ShipEngine("<YOUR_API_KEY_HERE>");
    }
}
import com.shipengine.ShipEngine;

public class ShipEngineDemo {
    public static void main() {
        ShipEngine shipengine = new ShipEngine(new HashMap<>() {{
            put("apiKey", "<YOUR_API_KEY_HERE>");
            put("pageSize", 75);
            put("retries", 3);
            put("timeout", 60000);
        }});
    }
}

Methods

Contributing

Contributions, enhancements, and bug-fixes are welcome! Open an issue on GitHub and submit a pull request.

Building

To build the project locally on your computer:

  1. Clone this repo
    git clone https://github.com/ShipEngine/shipengine-java.git

  2. Install dependencies
    mvn install

  3. Build the code
    mvn package

  4. Lint the code
    mvn checkstyle:check

  5. Run the tests
    mvn test

VS Code Setup

Install the Java Extension Pack to help write, test and debug the application, and install Checkstyle for Java to enable code formatting.

Committing

This project adheres to the Conventional Commits specification.