Question

JavaScript (Node) - How do i get messageStore list using multiple message types?

  • 19 March 2020
  • 2 replies
  • 477 views

Hello,

I'm using ringcentral-ts in my node application.

Trying to get messageStore for SMS and VoiceMail only by ringCentral.account().extension(extentionId).messageStore().list(params)


In params, there is a property called messageType which defined as:


/**

* The type of the resulting messages. If not specified, all messages without message type filtering are returned. Multiple values are accepted

*/

messageType?: 'Fax' | 'SMS' | 'VoiceMail' | 'Pager' | 'Text';


My question is how do i actually query for multiple types?

(There is a compilation error if i'm trying to put multiple values for messageType)


Thanks!




2 replies

Userlevel 1

Simply put them in an array ["Fax", "SMS"] etc.

Phong, thanks for your reply.

Unfortunately i can't use an array because of messageType definition:

Reply