I am trying to create an organization from an AWS Lambda function using the api. It works properly when we run the same function from any other place (dev machine). I tried it using the pipedrive node js client and also using a normal rest client too.
I get the following error when I await the promise using needle
http client.
Error: socket hang up
at createHangUpError (_http_client.js:299:15)
at TLSSocket.socketCloseListener (_http_client.js:331:23)
at emitOne (events.js:121:20)
at TLSSocket.emit (events.js:211:7)
at _handle.close (net.js:567:12)
at TCP.done [as _onclose] (_tls_wrap.js:356:7)