Authentication problem in Google Sheets Write action

How to fix authentication errors when writing to Google Sheets from ChronoForms.

Overview

The error occurs because the Service Account JSON file path is incorrectly set, often by using a link instead of the actual server file path.
Download the JSON credentials file from your Google Cloud Console, upload it to your server, and enter the full server file path into the CF action's Service Account JSON file path field.

Answered
ChronoForms v8
Mm Mmax2 05 Oct, 2024

Good morning, I'm trying to test the "Google Sheets Write" action in my form.

I set the permissions in my google sheet to "Anyone with the link" and set the role to "Editor".

In Chronoforms 8 I filled the "Sheet ID" field with the ID I got from the address bar, and the "Service Account JSON file path" field with the link I copied form the previous step.

In the debug I get the following: (error code 401) 

Request is missing required authentication credential. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project.

How can I solve this problem?

Thank you very much.

Max_admin Max_admin 07 Oct, 2024
Answer

as per the config hints, the sheet id is available in the address bar when the sheet is opened and the service account json credentials file should be downloaded from your Google account and uploaded to your server then the path should be added to the action settings

Authentication problem in Google Sheets Write action image 1

Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
This topic is locked and no more replies can be posted.