authorjapps / authorjapps/zerocode

Unable to pass array to body of request from previous API response.

Open
#531 6 comments 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
1k
Forks
453
Avg merge
7d 2h
Merged PRs (30d)
5

Description

API response of previous POST request:
"dtcIds" : [ "#37:1498", "#37:1499", "#37:1502", "#37:1503" ]

Need to pass this whole array to body of request - But After running getting in logs like:
"request": {
"headers": {
"locale": "${locale}" },
"body": {
"dtcIds": "${$.previousRequest.response.body.dtcIds[?(@.*)]}"
}

In logs it seems like,
![zerocode_backSlash](https://user-images.githubusercontent.com/57187905/180158842-a376d66d-fc08-43f5-83aa-8d01bb365793.png)

I don't want backword slash there ....Please help me to do it.
Please refer attached screenshot.

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the previous POST response containing the dtcIds array and the following request using the expression shown in the issue. Inspect how the request body expression is evaluated and serialized; done means the complete array reaches the next request without added backslashes or string quoting.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, json
Domain
api, testing
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.