# JSON parameter needs to be a valid JSON

**URL:** <https://community.n8n.io/t/json-parameter-needs-to-be-a-valid-json/102257>\
**Category:** Questions\
**Created:** [16 أبريل 2025، 11:49م UTC](https://community.n8n.io/t/json-parameter-needs-to-be-a-valid-json/102257 "2025-04-16T23:49:39Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ronnie\_Ysela\_Craig](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/ronnie_ysela_craig/32/73750_2.png) [@Ronnie\_Ysela\_Craig](https://community.n8n.io/u/Ronnie_Ysela_Craig)\
**Post date:** [16 أبريل 2025، 11:49م UTC](https://community.n8n.io/t/json-parameter-needs-to-be-a-valid-json/102257/1 "2025-04-16T23:49:39Z")

</div>

## JSON parameter needs to be a valid JSON

## What is the error message (if any)?

## Please share your workflow

[stuck on HTTP node](https://www.loom.com/share/2f2300ce64e54e19a92760891841b7fc?sid=aa2feb9d-4d03-44d5-a1ab-bc66f0ef384d)

 ![Screenshot (162)](https://europe1.discourse-cdn.com/n8n/original/3X/8/6/86a22bc3fd4ffb6faa35b93887d6c41d89051ccd.png)  
 ![Screenshot (163)](https://europe1.discourse-cdn.com/n8n/original/3X/9/c/9c420c51bf3098346e2c44aa1475726ed4211ff2.png)  
 ![Screenshot (164)](https://europe1.discourse-cdn.com/n8n/original/3X/6/5/65519049f79da0792b41b776f5b16f70b9323f50.png)  
 ![Screenshot (165)](https://europe1.discourse-cdn.com/n8n/original/3X/2/4/24fe855f05610d9c3b90f6c04108ebbac3a25d77.png)

```auto
(Select the nodes on your canvas and use the keyboard shortcuts CMD+C/CTRL+C and CMD+V/CTRL+V to copy and paste the workflow.)

```

## Share the output returned by the last node

## Information on your n8n setup

- **n8n version:** 1.86.1
- **Database (default: SQLite):**
- **n8n EXECUTIONS\_PROCESS setting (default: own, main):**
- **Running n8n via (Docker, npm, n8n cloud, desktop app):**
- **Operating system:**

---

<div class="post-metadata">

**Author:** ![mohamed3nan](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/mohamed3nan/32/188347_2.png) [@mohamed3nan](https://community.n8n.io/u/mohamed3nan)\
**Post date:** [17 أبريل 2025، 12:12ص UTC](https://community.n8n.io/t/json-parameter-needs-to-be-a-valid-json/102257/2 "2025-04-17T00:12:55Z")

</div>

Hi @Ronnie_Ysela_Craig

The last screenshot indeed shows not valid JSON,  
Try this expression:

```auto
"prompt": {{ JSON.stringify( $("AI Agent").item.json.output ) }},

```

---

<div class="post-metadata">

**Author:** ![Ronnie\_Ysela\_Craig](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/ronnie_ysela_craig/32/73750_2.png) [@Ronnie\_Ysela\_Craig](https://community.n8n.io/u/Ronnie_Ysela_Craig)\
**Post date:** [17 أبريل 2025، 12:27ص UTC](https://community.n8n.io/t/json-parameter-needs-to-be-a-valid-json/102257/3 "2025-04-17T00:27:18Z")

</div>

i"m testing it out now, that helped me move forward past that node. Thank you @mohamed3nan what an amazing group this is here!

---

<div class="post-metadata">

**Author:** ![mohamed3nan](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/mohamed3nan/32/188347_2.png) [@mohamed3nan](https://community.n8n.io/u/mohamed3nan)\
**Post date:** [17 أبريل 2025، 12:29ص UTC](https://community.n8n.io/t/json-parameter-needs-to-be-a-valid-json/102257/4 "2025-04-17T00:29:38Z")

</div>

You’re welcome, please make that reply as the solution ✅, if your issue got resolved 🙏🏻

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/system/32/195824_2.png) [@system](https://community.n8n.io/u/system)\
**Post date:** [24 أبريل 2025، 12:30ص UTC](https://community.n8n.io/t/json-parameter-needs-to-be-a-valid-json/102257/5 "2025-04-24T00:30:22Z")

</div>

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.
