Nodejs Sdk - How to resolve connect.describeContact is not a function?

0

I am trying to make a call to describeContact operation using the AWSJavaScriptSDK. I am following the documentation but somehow the call is not working. Below is my code.

const params = {
  ContactId: 'some_value', 
  InstanceId: 'some_value'
};

const attributes = await connect.describeContact(params).promise();

I receive -

connect.describeContact is not a function

Interestingly, when I replace describeContact with getContactAttributes in the call, I no longer receive "not a function" error and it works just fine (after I change the params). Both the operations have exactly the same signature.

Can someone please guide me here ?
Connect api version = 2017-08-08

Upgrading to the latest version of aws-sdk didn't help either.

Naxi
질문됨 2년 전223회 조회
1개 답변
0

Hi,

there error can indicate two things:

  1. There is a invisible character since it errors with connect.describe and not connect.describeContact
  2. Most likely - You need to update your aws-sdk dependency. describeContact() is a preview one and may not included in the SDK version you currently use.

Best

profile pictureAWS
faddi
답변함 2년 전
  • Sorry for not posting the exact error. It says - connect.describeContact is not a function. And I already tried updating the sdk to latest avaialble version. I still get the same error for this particular function.

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠