Getting key from a collection returned in output

i used Eden ai to generate a json object, it has 4 key-value pairs of data,
checked with chatgpt and it was a valid json object
the eden module is set to return as dict

If I manage to get a value returned like this:
{
“Dual Drivers Rock Your World”: “The Liberty 5 features a dual-driver setup that creates concert-hall quality sound in each earbud.”,
“Marathon Battery Life”: “These earbuds last 9 hours on a single charge, with the case providing up to 33 hours of total playtime.”,
“Ultimate Comfort Design”: “Multiple ear tip options allow for perfect fit comfort, making 3-hour wear sessions completely forgettable.”,
“Premium Features, Budget Price”: “With wireless charging and effective noise cancellation, these earbuds deliver premium features without the premium price tag.”
}

Then set a variable with using value called:
generatedText

Then why does this not work:
{{keys(35.generatedText)}}

35 is the number of the Set Variable module. 35.generatedText is a Collection type, so it should work right?

it just returns empty

It seems, this is not a valid json.

Check here: https://jsonformatter.org/
or
here: https://jsonformatter.curiousconcept.com/

I don’t this site is accurate or functioning properly, I mean it cant even validate empty curly brackets properly:

Use the other tester.
Whenever I had json issues, I checked them with one of the two testers and corrected them accordingly.
Error was gone in any case.

The above is not valid JSON. You can verify this by copy-pasting into jsonformatter.org

Could you please try providing it again with the following instructions below?


1. This forum might have or already changed your text

When pasting text into this forum, you should format the example text using the rich-text editor, otherwise the forum software might modify the displayed text, and you might get incorrect answers from others because of it.

Some things this forum software might do to mangle your text:

– remove extra spaces (which may be necessary)
– convert links to titles (when copied is incorrect)
– incorrect joined links
– convert single and double quotes to smart angled quotes (“ ”)
– emojis
– etc.

This interferes with you receiving correct answers, because it:

– makes JSON invalid (you can check by copy-pasting into jsonformatter.org)
– makes incorrect text examples when we need to build a pattern for text parsing

2. To prevent this in future, please format text in code blocks

These are the two ways to format text so that it won’t be modified by the forum:

  • Method 1: Type code block manually

    Add three backticks ``` before and after the content/bundle, like this:

    ```
    content goes here
    ```

  • Method 2. Highlight and click the format button in the editor

3. You might need to re-copy the original text

Once the post has been submitted, it’s too late to format it since it’s already butchered, and you need to make a re-copy of the text, and format it before submitting the forum post.

Please let us know once you have corrected the issue. This will avoid others potentially providing wrong answers based on incorrect text in your question.

Thank you!

@samliew