I would like to export the results of a single record to CSV or a spreadsheet row. As I was unable to find a method of exporting to CSV from a trigger I have chosen to export to a Google sheet using a connector. To do this a connection to https://sheets.googleapis.com has been created. After creating and verifying the connection to the domain, a function name of [POST] “******” to GoogleSheet with the connection address [Post]https/sheets.googleapos.com/v4/spreadsheets/xxxx/value/sheet1!1:1:apend was added.
(The sheetid was recovered from “anyone on the internet with this link can edit” share, and the spreadsheet has been published to the web).
For inputs I’ve created:
Spreadsheet ID => Sheet ID as the value
Range => Sheet1! 1:1
ID => Serial
and for outputs:
Spreadsheet ID => Sheet ID as the value
UpdateRows=> 1
After testing this configuration I generate a 404 error leading me to believe there is a problem with my Post url. Here are the test results logs.
Error 404 (Not Found)!!1
*{margin:0;padding:0}html,code{font:15px/22px arial,sans-serif}html{background:#fff;color:#222;padding:15px}body{margin:7% auto 0;max-width:390px;min-height:180px;padding:30px 0 15px}* > body{background:url(//www.google.com/images/errors/robot.png) 100% 5px no-repeat;padding-right:205px}p{margin:11px 0 22px;overflow:hidden}ins{color:#777;text-decoration:none}a img{border:0}@media screen and (max-width:772px){body{background:none;margin-top:0;max-width:none;padding-right:0}}#logo{background:url(//www.google.com/images/branding/googlelogo/1x/googlelogo_color_150x54dp.png) no-repeat;margin-left:-5px}@media only screen and (min-resolution:192dpi){#logo{background:url(//www.google.com/images/branding/googlelogo/2x/googlelogo_color_150x54dp.png) no-repeat 0% 0%/100% 100%;-moz-border-image:url(//www.google.com/images/branding/googlelogo/2x/googlelogo_color_150x54dp.png) 0}}@media only screen and (-webkit-min-device-pixel-ratio:2){#logo{background:url(//www.google.com/images/branding/googlelogo/2x/googlelogo_color_150x54dp.png) no-repeat;-webkit-background-size:100% 100%}}#logo{display:inline-block;height:54px;width:150px}
404. That’s an error.
The requested URL /v4/spreadsheets/xxxxsmUttJSWklA/values/Sheet1%201:1:append%20%20 was not found on this server. That’s all we know.
thanks for posting, welcome to the Tulip Community!!
just to confirm, have you set up the OAuth 2.0 on the Connector Details page?? this is how it should be set up (you will need to create a new Google Project and create an API).
A Google project has been create with a client ID and client secret, but I only have the option to enter the prefix and token. Both are listed under OAuth 2(Bearer token).
When testing [POST] connection I am getting a 401 error. “Request is missing required authentication credentials”, but if I change the function to [Get] data from the spreadsheet using the configuration in this post Connecting to Google Sheets the test returns the field values of the sheet. This is what I currently have
could you confirm that you entered all the information in the OAuth Connection Details are as follows?? (replacing gio with your instance name, and the correct Client ID and Client Secret):
@Neo - I think this is probably got to do with how OAuth is configured on Google’s end.
May be you can take a quick look at the documentation of setting up an API on Google Cloud & enabling Oauth?
Here’s the documentation: Setting up OAuth 2.0 - Google Cloud Platform Console Help