Flow Error : JSON must be an object or an array
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-18-2024 06:21 AM
Hi,
we receive an error in some cases in a subflow that handles out New Hire Candidates.
The error we receive is the following " Failed to iterate on data stream: com.glide.transform.transformer.exceptions.InvalidStructureException: JsonStreamParser[0]: JSON must be an object or an array: 'A' "
This is not a case for all executions of the flow only some of them do have the error.
Could anyone please help me to understand better where the issue could be and what to check?
Thank you.
Best regards,
Marketa
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-18-2024 09:09 AM
Hello @marketa_w ,
Check the below:
1. Review the input data that your flow is receiving. Ensure that it is properly formatted as JSON and contains either an object or an array.
2. Verify that the input data is correctly structured according to the requirements of your flow. Use some debug messages to print your input before passing.
Please Mark My Answer as Helpful and Accept as Solution, if you find this article helpful or resolves your issue.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-18-2024 10:12 AM
Hi @marketa_w Please check your input data type in the subflow.if the data type is object ,Array.object or JSON , please change and take input type as a string
You can Change data type in json format inside the custom script