We did it. And it works.
Here are a few key changes to the workflow and content.
Edit Fields
{{(() => {
const text = $json.message.text.split('\n').slice(1).join('\n').trim();
return {
"fibery/rich-text": [
{
text,
type: "paragraph"
}
]
};
})()}}
HTTP Request Query
JSON
[
{
"command": "fibery.entity/query",
"args": {
"query": {
"q/from": "My Space/Content Ideas",
"q/select": [
"fibery/id",
{
"My Space/Description": [
"Collaboration~Documents/secret"
]
}
],
"q/where": ["=", ["fibery/id"], "$id"],
"q/limit": 1
},
"params": {
"$id": "{{ $json.entityId }}"
}
}
}
]
Set Entity Description
Manual Mapping
descriptionText
String
{{ $('Edit Fields').item.json.description['fibery/rich-text'].map(p => p.text).join('\n\n') }}
HTTP Request2
URL: https://myworkspace.fibery.io/api/documents/{{ $('HTTP Request Query').item.json.result[0]['My Space/Description']['Collaboration~Documents/secret'] }}?format=md
JSON
{{ { content: $json.descriptionText } }}
DONE