Join the Webstudio community

Updated yesterday

Not possible to add data from Notion Database response to a variable resource URL?

At a glance

A community member is attempting to use a Notion database field to define a BlueSky post ID, and then use the BlueSky API to pull in details or responses to that post to allow for people to reply to the BlueSky post and have it show as a comment on their blog. However, they are running into an issue where they cannot add a resource into the expression editor of another resource. A community member responds that to avoid performance issues due to request waterfalls, nesting resources is forbidden, and suggests implementing a custom backend with tools like n8n or Cloudflare worker instead.

Useful resources
I'm attempting to use a field in a Notion Database to define the Post ID from a BlueSky. Then Use BlueSky's API to pull in details or responses to that post to allow for people to reply to the BlueSky post and have it show as a comment on the blog. The problem I'm running into is that I can't add resource into the expression editor of another resource. Is there a work around for this?
Plain Text
"https://api.bsky.app/xrpc/app.bsky.feed.getPostThread?uri=at://did:plc:n6com3b6tkpq76vr5n7xqutu/app.bsky.feed.post/" + notionData.data.results[0].properties["BlueSky Post"]["rich_text"][0]["plain_text"]


I thought this would work but it yellow underlines notionData and says "notionData" is not defined in the scope. I've tried putting the Notion variable in the Global Root, Body and shifting the BlueSky variable at the same level and below.

I will note I'm not set on using Notion for this but it was quick and easy for me to set up with the blog that is currently using Zen Blog for the CMS (which doesn't support something like this, and even if it did, it would have the same problem).
Marked as solution
To avoid performance issues because of request waterfalls we forbid nesting resources. If you really need this better implement custom backend with something like n8n or cloudflare worker and connect it to webstudio.
View full solution
B
C
2 comments
To avoid performance issues because of request waterfalls we forbid nesting resources. If you really need this better implement custom backend with something like n8n or cloudflare worker and connect it to webstudio.
Got it. Bummer, it's not worth implementing then at this point.
Add a reply
Sign up and join the conversation on Discord