• Resolved phlipineck

    (@phlipineck)


    Hi!
    Me again… I’ve hit one thing I can’t solve with the steps currently available, and I wanted to ask if it’s something you’d consider adding.

    The problem: I’m passing a large scraped text blob (Firecrawl markdown, roughly 20,000 characters) into the body of an HTTP Request step. The body is JSON. The markdown contains double quotes, backslashes, and newlines — which break the JSON string it’s embedded in, and the request fails before it’s even sent (“failed to fetch”). I can only pass short, clean values right now.

    What would solve it — either of these, whichever fits the plugin better:

    1. A variable filter — so when you insert a variable via the {} data picker, you could optionally apply something like {{ firecrawl.json.data.markdown | json_escape }}. That filter would escape " → \", \ → \\, and newlines → \n, making the value safe inside a JSON string.
    2. A Transform step — a small step that takes an input value, applies a chosen transformation (JSON escape / URL encode / truncate to N chars), and outputs the result to a new variable later steps can reference.

    The first would be my preference if it’s not too much bother, since it keeps the workflow diagram tidy — but honestly either would work, and I’d trust your judgement on which fits better with how Meow is designed.

    The workflow it’s for, in case it helps:
    Webhook → Firecrawl (scrape page) → Gemini (write article from scraped content) → Create Post (WordPress draft).

    It’s all working right now when I pass a short value — I’ve just hit the length/escaping wall with the full scraped page.

    Thanks again for building it — genuinely appreciate the work.

Viewing 1 replies (of 1 total)
  • Plugin Author Jordy Meow

    (@tigroumeow)

    Glad you are here @phlipineck, with your feedback always! 😊

    Actually, this already exists, it’s just not documented well enough yet (my fault, will fix). Every reference accepts formatting filters after a pipe, and one of them is json. It turns the value into a JSON literal, with the quotes, backslashes, newlines and everything else escaped for you. Since it adds the surrounding quotes itself, you write it in place of a quoted value, not inside one. So the body of your HTTP Request step would look like this:

    { “content”: {{ scrape.markdown | json }} }

    Replace scrape.markdown with your own step and field, exactly as the Insert data button gives it to you, then just add the filter. A 20,000 character Firecrawl blob is no problem.

    One more thing worth checking while you’re in that step: the body is sent exactly as you typed it, and no Content-Type header is added automatically. If the API you’re calling is strict about that, put { “Content-Type”: “application/json” } in the Headers field.

    Other filters available today, in case they help along the way: upper, lower, ucfirst, trim, strip_tags, truncate:N, default:”…”, date:”F j, Y” and number_format.

    Thanks for sharing this, and good luck with the article pipeline! 😊 Please let me know how it goes!

Viewing 1 replies (of 1 total)

You must be logged in to reply to this topic.