twilio / twilio-node

Node.js helper library
MIT License
1.37k stars 495 forks source link

userConversations api answer is different from one in the documentation or from cURL #953

Open mikhail-uchi-ru opened 10 months ago

mikhail-uchi-ru commented 10 months ago

Issue Summary

I use simple example from https://www.twilio.com/docs/conversations/api/user-conversation-resource#list-all-of-a-users-conversations

client.conversations.v1
.users(identity)
.userConversations
.list({limit: 1})
.then(userConversations => {
    console.log(userConversations)
});

as an output I get an array of conversations - no meta, no nothing

If I do cURL from the docs - I get answer in proper format

Steps to Reproduce

  1. Clone latest twillio-node repo
  2. Paste the code from https://www.twilio.com/docs/conversations/api/user-conversation-resource#list-all-of-a-users-conversations
  3. Check the resulting data

Technical details:

mikhail-uchi-ru commented 10 months ago

UPDATE So I did

    console.log(client._httpClient.lastResponse);

And there is, indeed, all the response data. Is there any reason we don't get it as a result?