Figured out how to POST data to blockspring and return store the response as multiple rows in my Bubble database.
I built a custom block to do math which returned a multiple value response. The issue is that the response was coming back a one big string (see “Fruity”).
Beautifying the response: My goal was to store Fruity: Field 1 and Field 2 in my bubble database as multiple rows.
{
“_blockspring_spec”:true,
“_errors”:,
“fruity”:“[
{
“field_1”:1,
“field_2”:“apple”
}
,{
“field_1”:2,
“field_2”:“banana”
}
,{
“field_1”:3,
“field_2”:“pear”}
]”
}
The Blockspring functions for returning a response ( eg. response$addOutput(), response$end()) were not returning a response in a format the Bubble Connector could natively recongize.
So, my solution was to rewrite the Blockspring input and output functions.
Here’s a link to a block that can return multiple key:values back to the Bubble Connector
https://open.blockspring.com/whitney-kramer/b14c276b617a881f3ac5ee6b5414f70a/code
I’ve created a demo in the Forum App for others to see the setup: Forum_app | Bubble Editor
Best.