Describe the problem/error/question
I am using the Apollo people search API endpoint. One of the query parameters is called person_titles and expects and array of strings containing job titles. Here is an example from the docs: [“sales director”, “director sales”, “director, sales”].
I am copy and pasting this example from the docs into my http node query parameters (set to JSON).
{
“person_titles”: [“sales director”, “director sales”, “director, sales”]
}
For some reason I am getting the format error below:
What is the error message (if any)?
Your request is invalid or could not be processed by the service
person_titles requires an array. You are passing in ActiveSupport::HashWithIndifferentAccess
I then changed the parameter to the following:
{
“person_titles[ ]”: [“sales director”, “director sales”, “director, sales”]
}
which showed me this error:
Your request is invalid or could not be processed by the service
An ActiveSupport::HashWithIndifferentAccess is passed in for a String field {“0”=>“sales director”, “1”=>“director sales”, “2”=>“director, sales”}.
So I assume that the problem is n8n is converting my input to some sort of indexed array before passing it to the module but I have no idea how to prevent this and even why it is an issue.
Any help on how to tackle this would be very much appreciated I have spent way too much time on this ;(
Please share your workflow
It does not seem like my workflow is loading properly but the code is there.
Information on your n8n setup
- n8n version: 1.85.4
- Running n8n via (Docker, npm, n8n cloud, desktop app): cloud
- Operating system: Windows