ShipEngine / shipenguin_web_app

The source code for the Shipenguin web app, this project serves as a reference implementation of address validation, rates, and labels powered by ShipEngine.

Home Page:https://shipenguin-dev.herokuapp.com/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Shipenguin Web App (In Development)

This is a reference implementation of the following ShipEngine API services:

  • Address Validation
  • Shipping Rates
  • Shipping Labels
  • The first step to run this source code locally, will be creating a .env file in the project directory. You can copy the contents of .env.example and add in your own values before starting the server.

    • Note: You will need to create a free ShipEngine Account to obtain Sandbox and Production API Key's and carrier_id's to run this application successfully.
  • Next, you will install the projects' dependencies at the command line.

    npm install && npm start
    
  • Go to the server address in your browser https://<ngrok_hash>.ngrok.io/ listening on port 8000. When you run npm start you will see the server address provided in your terminal.

  • This app also uses Stripe for payments.

    • You can use the following test card information to pay for the label:
    • 4242 4242 4242 4242 CVV:<any 3 digits> EXP:<any future date> ZIPCODE:<any 6 digits>

Local Development

When running this code in development mode if you do not have an NGROK account, use the following npm script:

npm run dev
  • This runs with the NODE_ENV set to production because there is logic in server/node/config.js on line 74.

If you have an NGROK account and have added your NGROK authtoken to your .env file, use the following npm script:

npm run dev:ngrok
  • This runs with the NODE_ENV set to development to trigger the NGROK config to use your NGROK authtoken and subdomain.

About

The source code for the Shipenguin web app, this project serves as a reference implementation of address validation, rates, and labels powered by ShipEngine.

https://shipenguin-dev.herokuapp.com/

License:MIT License


Languages

Language:CSS 97.2%Language:JavaScript 1.6%Language:HTML 1.0%Language:Shell 0.1%