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
Having a small issue with the incidents.listIncidents endpoint (PD docs), when trying to pass through statuses. PagerDuty needs them passed through as an array, but I can't figure out how to pass them in a format that will be appropriately encoded (statuses[]=triggered) by Node's querystring library, which is being used here.
I'm not sure if I'm missing something obvious... or whether another querystring helper library might be required instead?
value of qs after line 34 in pd.js: ?statuses[]=triggered
response from PagerDuty: hopefully a list of just triggered incidents 😄
Is there something else I haven't thought of... or otherwise something else this library can do to help these through to the querystring sent to PagerDuty?
Hi there,
Thanks for putting this together!
Having a small issue with the
incidents.listIncidents
endpoint (PD docs), when trying to pass through statuses. PagerDuty needs them passed through as an array, but I can't figure out how to pass them in a format that will be appropriately encoded (statuses[]=triggered
) by Node's querystring library, which is being used here.I'm not sure if I'm missing something obvious... or whether another querystring helper library might be required instead?
What I've tried
qs
after line 34 in pd.js:?statuses=triggered
Invalid Input Provided / error 2001 / Statuses must be a Array.
qs
after line 34 in pd.js:?statuses=triggered
Invalid Input Provided / error 2001 / Statuses must be a Array.
qs
after line 34 in pd.js:?statuses=%5B'triggered'%5D
Invalid Input Provided / error 2001 / Statuses must be a Array.
qs
after line 34 in pd.js:?
What I'm looking for
qs
after line 34 in pd.js:?statuses[]=triggered
Is there something else I haven't thought of... or otherwise something else this library can do to help these through to the querystring sent to PagerDuty?
For instance, it looks like query-string provides an
arrayFormat
option which might fix this issue: https://www.npmjs.com/package/query-string#arrayformat-1The text was updated successfully, but these errors were encountered: