Developer Q&A

Ask a Question
Back to All

Connecting to the API with Node.js

I am looking to use the API with nodejs. I have the URL Discovery WSDL, https://am-apilocator.corrigo.com/wsdk/CorrigoService.asmx?wsdl, but when I try to set up a client using the soap npm module, it times out with no response. I have tested out a few public WSDL’s so I’m confident it isn’t an issue with the node module I’m using. I’m thinking it has to do with the credentials I’d have to pass in to authenticate, which I’ve tried a few different ways to no avail. Here is the error I get with the Address and Port x'd out.

{ Error: connect ETIMEDOUT xxx.xxx.xxx.xxx:xxxxx
    at Object._errnoException (util.js:1003:13)
    at _exceptionWithHostPort (util.js:1024:20)
    at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1195:14)
  errno: 'ETIMEDOUT',
  code: 'ETIMEDOUT',
  syscall: 'connect',
  address: 'xxx.xxx.xxx.xxx',
  port: xxxxx }