You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, the SingleFilterSearchRequest interface in the intercom-node library does not enforce that the value property be an array when the operator is set to "IN" or "NIN". This can lead to runtime errors if a string is provided instead of an array.
Proposed Solution:
Modify the SingleFilterSearchRequest interface to ensure type safety by differentiating between operators that require an array for value and those that do not.
The text was updated successfully, but these errors were encountered:
This is a bigger issue. With typescript it doesn't even allow you to give an array value. It requires it to be type string all the time. Even when the operator is IN or NIN.
Apologies for the delayed response here @kang8 - thanks for the issue! It looks like this is a gap in Intercom's OpenAPI specification defined here.
We'll need to update the OpenAPI spec to include the missing constraints and regenerate the SDK. If this is urgent for you, please feel free to opening a pull request to the 2.11 OpenAPI spec here. Otherwise, we'll confirm the expected behavior with the Intercom team and try to have an update for you here soon.
Description:
Currently, the
SingleFilterSearchRequest
interface in theintercom-node
library does not enforce that thevalue
property be an array when theoperator
is set to"IN"
or"NIN"
. This can lead to runtime errors if a string is provided instead of an array.Proposed Solution:
Modify the
SingleFilterSearchRequest
interface to ensure type safety by differentiating between operators that require an array forvalue
and those that do not.The text was updated successfully, but these errors were encountered: