How to retrieve data via JSONP with dynamic IDs?

How to retrieve data via JSONP with dynamic IDs?

Here's an example of how the API works from a third party provider.

https://app.example.com/api/head/category.json?_authbykey=56a7d8c531231c4058361687&_fields[]=name&id[$in][]=56d0b73131231c210d494e3e&id[$in][]=570fa55491231c001d4aeb98&id[$in][]=570fa55f12331cdf3d804b86&id[$in][]=570fa56d32123ce53f804ab0

I gathered all my IDs into a variable "parentIDs" and below is my code thus far.

  1. $.getJSON('https://app.example.com/api/head/suggest.jsonp?', {
  2.                         _authbykey: "56a7d8c531231c4058361687",
  3.                         _fields: ["name"],
  4.                         id:{
  5.                             "$in":[parentIDs]
  6.                             },
  7.                         callback: "?"
  8.                         }, function(dataParent) {
  9.                             refineSearch = "<fieldset><legend>Refine your search</legend>";
  10.                             $.each(dataParent.data, function(i, parent) {
  11.                                 refineSearch += '<input type="checkbox" name="animal" value="' + parent.id + '" />' + parent.name + '<br />';
  12.                                 console.log(parent.name);
  13.                             });
  14.                             refineSearch = "</fieldset>";
  15.                     });

I'm not getting even a console.log in this code. My guess it has something to do with the ID parameter. In the Params, this is what it showed:

_authbykey=56a7d8c531231c4058361687
_fields[]=name
callback=?
id[$in][]="56d0b73131231c210d494e3e","570fa55491231c001d4aeb98","570fa55f12331cdf3d804b86","570fa56d32123ce53f804ab0"

Any help is much appreciated.