Coder Social home page Coder Social logo

shipstation-node's Introduction

Hello there ๐Ÿ‘‹, I'm Keenan Jaenicke

Software Engineer based outta Indy!

shipstation-node's People

Contributors

alphakilo45 avatar antonioxdias avatar brandon93s avatar chrisforeman avatar copleykj avatar dependabot[bot] avatar jakehewitt avatar kjaenicke avatar tkdave avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

shipstation-node's Issues

List of carrier codes?

Does anyone have a complete list of carrier codes?

Also, I know this is more of a question for shipstation, but maybe it will help somebody else just picking this package up-- I've been playing around on postman and seem to be getting: "No applicable services were available for the configured shipment" for almost all my attempts, other than from stamps_com... do we need to configure other carriers to get their rates?

e.g. this returns no rates result

{
  "carrierCode": "fedex",
  "fromPostalCode": "03801",
  "toPostalCode": "90712",
  "weight": {
    "value": 60,
    "units": "pounds"
  },
  "toCountry": "US"
}

Is it just that fedex truly can't handle this delivery between these area codes or is this a matter of configuring the provider/carrier in my settings?

The same options but with stamps_com does return rates

{
  "carrierCode": "stamps_com",
  "fromPostalCode": "03801",
  "toPostalCode": "90712",
  "weight": {
    "value": 60,
    "units": "pounds"
  },
  "toCountry": "US"
}

Lastly, has anyone found a pattern for which carriers top out in terms of weight? I noticed stamps_com seems to max around around 70-80 pounds for most of the combinations I've tried.

and, of course, thanks for publishing this.

TypeScript duplicate warning: ...node_modules/shipstation-node/dist/index.js' imported multiple times import/no-duplicates

It is a warning, so not breaking, but would like it to go away, without having to suppress the warning.

When deploying to Google Cloud Functions, the following warning is displayed in logs.

/home/me/AndroidStudioProjects/order_fulfillment/functions/src/lib/helperFunctions.ts
   10:25  warning  '/home/me/AndroidStudioProjects/order_fulfillment/functions/node_modules/shipstation-node/dist/index.js' imported multiple times  import/no-duplicates
  112:28  warning  '/home/me/AndroidStudioProjects/order_fulfillment/functions/node_modules/shipstation-node/dist/index.js' imported multiple times  import/no-duplicates

I'm importing both ShipStation and ShipStationAPI so I can set the Promise return type.

In my helperFunctions.ts I'm importing shipstation-node by doing the following:

import ShipStation from 'shipstation-node'
import ShipStationAPI from 'shipstation-node'

/**
 * Set the ShipStation API client.
 * https://github.com/kjaenicke/shipstation-node
 * @return {ShipStationAPI | null} The ShipStation client.
 */
export async function setShipStationClient(): Promise<ShipStationAPI | null> {
  try {
    return new ShipStation({
      apiKey,
      apiSecret,
      retry: { retries: 3 },
    })
  } catch (error) {
    functions.logger.error(error)
    return null
  }
}

license

Hi.
Your package looks great. can you add a license to it? I want to know if I can fork it
thanks

Shipments getAll Return Type is incorrect

Hey, first of all, thank you for all of work on this, it's been really helpful!

When attempting to use shipments.getAll, I noticed that the return type of the method is Promise<IShipment[]> when it should be Promise<IShipmentPaginationResult> (which doesn't currently exist) similar to the orders.getAll return. Because of this, attempting to access shipments from the returned object fails. I was able to work around it by importing your models and creating my own:

  interface IShipmentPaginatedResults extends Models.IPaginatedResult {
    shipments: Models.IShipment[];
  }

and then casting the results

  const { shipments, page, pages } = (await shipstation.shipments.getAll({
    pageSize: 500,
    shipDateStart: orderDateStart,
  })) as unknown as IShipmentPaginatedResults 

Just wanted to give you a heads up. Thanks again!

--DJ

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.