I am using JotForm on my website and I am trying to save the results into a wix-data collection. The only way I know how to is to use an HTTP function. When I sent a request from jotform to pipedream, it worked.
However, I HAVE NO IDEA HOW TO SET UP A COLLECTION TO HOLD THIS DATA. Do I need to create a header on wix for each header below; or does can wix add them automatically when it is sent a request like this.
{
"method": "POST",
"path": "/",
"query": {},
"headers": {
"x-forwarded-for": "111.111.112",
"x-forwarded-proto": "https",
"x-forwarded-port": "443",
"host": "xxx.m.pipedream.net",
"x-amzn-trace-id": "Root=1-5fe69bcc-6513cca1732f704830e1ac3d",
"content-length": "1343",
"accept": "*/*",
"content-type": "multipart/form-data; boundary=------------------------1c5ebeb8fb7e1886"
},
"bodyRaw": "{\"formID\":\"203582761576059\",\"submissionID\":\"4847578830816371883\",\"webhookURL\":\"https://xxx.m.pipedream.net\",\"ip\":\"111.111.111\",\"formTitle\":\"Form\",\"pretty\":\"Name:John Smith, Just write anything .:jotform_untitled_markdownjust a test, Title your response (optional):Title\",\"username\":\"chrisfurlong03\",\"rawRequest\":\"{\\\"slug\\\":\\\"submit\\\\/203582761576059\\\",\\\"q1_name\\\":{\\\"first\\\":\\\"John\\\",\\\"last\\\":\\\"Smith\\\"},\\\"q2_justWrite\\\":\\\"just a test\\\",\\\"q6_titleYour\\\":\\\"Title\\\",\\\"file\\\":\\\"\\\",\\\"preview\\\":\\\"true\\\"}\",\"type\":\"WEB\"}",
"body": {
"formID": "203582761576059",
"submissionID": "4847578830816371883",
"webhookURL": "https://xxx.m.pipedream.net",
"ip": "111.111.111",
"formTitle": "Form",
"pretty": "Name:John Smith, Just write anything.:jotform_untitled_markdownjust a test, Title your response (optional):Title",
"username": "johnsmith0",
"rawRequest": "{\"slug\":\"submit\\/203582761576059\",\"q1_name\":{\"first\":\"John\",\"last\":\"Smith\"},\"q2_justWrite\":\"just a test\",\"q6_titleYour\":\"Title\",\"file\":\"\",\"preview\":\"true\"}",
"type": "WEB"
}
The end goal is to somehow extract the data from the following header from above:
"rawRequest": "{\"slug\":\"submit\\/203582761576059\",\"q1_name\":{\"first\":\"John\",\"last\":\"Smith\"},\"q2_justWrite\":\"just a test\",\"q6_titleYour\":\"Title\",\"file\":\"\",\"preview\":\"true\"}",
how do I take that and put it into a collection?