Google sheets

This plugin extracts the values of a cell, column or row from a google sheet document.

introduction

Ver. 17-10-2022

This plugin extracts the values of a cell, column or row, from a google sheet document.

Type: Server plug-in

Previous configuration

In console.cloud.google.com:

image-1666008066266.png

You must choose a project or create a new one:

image-1666008365140.png

The google drive API must be enabled, we can look for it in the "library" section.

image-1666008470354.png

Once enabled, in the credentials section, we must create a password for our service account:

image-1666008590100.png

A json file will be downloaded, once this is done the next thing will be to enable the google sheets API.

image-1666008698072.png

Once enabled, the last part will be to share the google sheets document with the project service account, the address is in the previously downloaded json:

image-1666008827161.png

 

Parameters

Parameter Description
--creds_json Path to the file with the credentials
--creds_base64 Base64-encoded credentials code.
--name Name of the googlesheet document
--cell The cell from which the data is expected, for example: "B1"
--row Row number. Specified with a number, for example: 2
--column Column number. Specified with a number, for example: 3
--sheet Name of the sheet in the document where the plugin will look. It must be exactly the same as the name it has, including spaces and capitalization, for example: "Sheet 1"
--onlydigits Set to 1 to parse non-digit values

 

a

Manual execution

./pandora_googlesheets --creds_json/creds_base64 <file credentials> --name <name document> --sheet <name-sheet> --cell <Number cell> --row <number-row> --column <number-column>

image-1683875273721.png

If the onlydigits parameter is used, a non-digit value will be parsed:

./pandora_googlesheets --creds_json/creds_base64 <file credentials> --name <name document> --sheet <name-sheet> --cell <Number cell> --row <number-row> --column <number-column> onlydigits 1

image-1683813865590.png