# Create JSON action Is Replacing emptystring with null

**URL:** <https://community.make.com/t/create-json-action-is-replacing-emptystring-with-null/52030>\
**Category:** Questions\
**Tags:** json\
**Created:** [August 21, 2024, 12:30pm UTC](https://community.make.com/t/create-json-action-is-replacing-emptystring-with-null/52030 "2024-08-21T12:30:43Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Connor](https://avatars.discourse-cdn.com/v4/letter/c/e99b99/32.png) [@Connor](https://community.make.com/u/Connor)\
**Post date:** [August 21, 2024, 12:30pm UTC](https://community.make.com/t/create-json-action-is-replacing-emptystring-with-null/52030/1 "2024-08-21T12:30:43Z")

</div>

Hi all. I’m getting some unexpected behavior where a create JSON step is intaking an emptystring but the json outputted has null instead of “”

Here’s my array aggregator where roster\_name and roster\_number are set to emptystring if the inbound fields are empty.

 ![Screenshot 2024-08-21 at 6.25.52 AM](https://europe1.discourse-cdn.com/flex013/uploads/make/original/3X/c/c/ccd613b6b6f98e45e122fffbf67e1d11150da927.png)

That array aggregator feeds into a Create JSON step

 ![Screenshot 2024-08-21 at 6.27.38 AM](https://europe1.discourse-cdn.com/flex013/uploads/make/original/3X/6/b/6b4fdda63fc1a8f65b0a707690a963e396f8c74b.png)

 ![Screenshot 2024-08-21 at 6.28.44 AM](https://europe1.discourse-cdn.com/flex013/uploads/make/original/3X/8/2/8291a614fcaae34e29ae188a1fb2f281b85becf6.png)

Here’s what the JSON output looks like when roster\_name and roster\_number are emptystring - as you see - it writes null when I want it to just write “” (emptystring)

![Screenshot 2024-08-21 at 6.30.12 AM](https://europe1.discourse-cdn.com/flex013/uploads/make/original/3X/3/f/3f1db11566e3d1b3b69b5363c4b577ea0bb48f53.png)

---

<div class="post-metadata">

**Author:** ![Connor](https://avatars.discourse-cdn.com/v4/letter/c/e99b99/32.png) [@Connor](https://community.make.com/u/Connor)\
**Post date:** [August 21, 2024, 12:31pm UTC](https://community.make.com/t/create-json-action-is-replacing-emptystring-with-null/52030/2 "2024-08-21T12:31:53Z")

</div>

FWIW, here’s how roster\_name and roster\_number are configured within the JSON data structure:

 ![Screenshot 2024-08-21 at 6.31.25 AM](https://europe1.discourse-cdn.com/flex013/uploads/make/original/3X/0/b/0b60bfddc8cac979bf196ddba0a07476d81f64ec.png)

---

<div class="post-metadata">

**Author:** ![Donald\_Mitchell](https://dub1.discourse-cdn.com/flex013/user_avatar/community.make.com/donald_mitchell/32/8749_2.png) [@Donald\_Mitchell](https://community.make.com/u/Donald_Mitchell)\
**Post date:** [August 21, 2024, 12:38pm UTC](https://community.make.com/t/create-json-action-is-replacing-emptystring-with-null/52030/3 "2024-08-21T12:38:59Z")

</div>

Your app ought to accept null.  
If it doesn’t, you can try passing {{space}} instead which would result in “roster\_name”:" "

---

<div class="post-metadata">

**Author:** ![Connor](https://avatars.discourse-cdn.com/v4/letter/c/e99b99/32.png) [@Connor](https://community.make.com/u/Connor)\
**Post date:** [August 21, 2024, 12:50pm UTC](https://community.make.com/t/create-json-action-is-replacing-emptystring-with-null/52030/4 "2024-08-21T12:50:41Z")

</div>

Trust me, I’m with you. This is being sent to a partner’s API who insists it needs to be an empty string instead of null. 🙄

---

<div class="post-metadata">

**Author:** ![samliew](https://dub1.discourse-cdn.com/flex013/user_avatar/community.make.com/samliew/32/13327_2.png) [@samliew](https://community.make.com/u/samliew)\
**Post date:** [August 21, 2024, 12:55pm UTC](https://community.make.com/t/create-json-action-is-replacing-emptystring-with-null/52030/5 "2024-08-21T12:55:35Z")

</div>

Instead of Create JSON, use Aggregate to JSON or a Text Aggregator.

Hope this helps! Let me know if there are any further questions or issues.

— @samliew

* * *

P.S.: Did you know, [the concepts](https://community.make.com/t/make-academy-course-overview/29699) of about 70% of questions asked on this forum are already covered in the [Make Academy](https://academy.make.com). Investing some effort into it will save you lots of time and frustration using Make later!

---

<div class="post-metadata">

**Author:** ![Make\_Bot](https://dub1.discourse-cdn.com/flex013/user_avatar/community.make.com/make_bot/32/14661_2.png) [@Make\_Bot](https://community.make.com/u/Make_Bot)\
**Post date:** [November 19, 2024, 1:57pm UTC](https://community.make.com/t/create-json-action-is-replacing-emptystring-with-null/52030/6 "2024-11-19T13:57:14Z")

</div>

This topic was automatically closed because it's resolved or inactive. Please, start a new topic.


