{ "embeds": ["0"] } error sending message with embeds to Discord

This topic was automatically generated from Slack. You can find the original thread here.

Shai Perednik : any ideas why this using a path in the embeds would fail for discord? I know I can construct the embed in a seperate nodejs element and return it, but trying to do this simple and quick as a test:

Danny Roosevelt : Hey it looks like there are 2 issues here:

  1. The "" around the value you’re trying to pass for the url field is getting evaluated literally, so Discord is getting it as {{steps…}} instead of http... like I think you’re intending.
  2. Within those "", we aren’t evaluating anything inside the {{}} because that’s not technically valid JS due to the {{}} at the top of that code block. You should actually just pass the variable directly, without the surrounding {{}}.

Danny Roosevelt : So this should do the trick!

"url": steps.send_http_request.$return.value.url

Shai Perednik : yep that worked ty

Shai Perednik : !!!

Danny Roosevelt : Nice, np!