Text styling removed when webhooked to another doc

Hi, I am using webhook to sent data from one doc to another. There are some text fields that have styling in. there are bullet points and line spacing.

When I push this info to another doc the styling is lost. I have also tried changing the fields from normal text fields to canvas fields but the styling is still lost.

is there a way to keep the styling when pushing data using webhooks or is this a limitation of webhook?

yep, this is how webhooks work, the data is flattened in JSON and it gets stripped from all properties like bold and color. cheers, christiaan

1 Like

It seems there is a solution that keeps the styling here:

But now I need a token for the pack that will work with all docs, since I am copying a template doc and it’s automations. Any ideas how to create an API token for this webhook that will work everywhere?

maybe @Paul_Danyliuk can share his insights, but the general rule is that no formatting is passed on via JSON. Cheers, Christiaan

To create a token that will work everywhere, you go to https://coda.io/account → API Settings → Generate API token without restrictions and with the write or read/write access.

And yes, the solution is to pass over the whole internal state of the formatted text object, i.e. to pass a

  "text", MyText._Merge()

and on the receiving side I guess you should

[Step 1 Result].ParseJson()._Deref_object("text")
1 Like

Thankyou @Paul_Danyliuk it works now!

1 Like

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