Google Drive Credential
FlowMint works in Google Drive as a service account: a Google identity for software, with its own email address and a key file instead of a password. It sees only the folders and shared drives you share with it.
How to set it up
Section titled “How to set it up”- In the Google Cloud console, create a project (or pick one) and enable the Google Drive API for it.
- Under APIs & Services → Credentials, create a service account.
It needs no project roles. Note its email address, which ends in
iam.gserviceaccount.com. - Open the service account, go to Keys, add a key of type JSON and download it. Keep this file like a password.
- In Google Drive, create or choose a shared drive for the workflow’s files, and add the service account’s email address to it as a Content manager (or a role that can add files).
- Store the whole key file as the
drive_service_accountcredential; see Managing credentials. - Copy the id of the folder the workflow should use: the part of its Drive
address after
/folders/. Use it asparent_idin the Drive steps.
What the test proves
Section titled “What the test proves”flowmint_test_credential with drive_service_account reads the stored
key and returns the service account’s email and project id. It does not
contact Google, so an ok means only that the key is stored and readable.
To prove Drive access, run a workflow with a drive_find_or_create_folder
step against your parent_id and check that the folder appears.
Limits and common problems
Section titled “Limits and common problems”- Files fail, folders work. The quota rule above: move the target into a shared drive.
auth_failedon every Drive step. The folder or shared drive is not shared with the service account’s email, or the Drive API is not enabled in its project.config_errorsaying the JSON is invalid. The stored value is not the whole key file, or it lacksclient_email. Store the file again.- You cannot find a folder FlowMint created. A folder the service account creates in someone’s My Drive is owned by the service account and does not show in Drive search. Open the parent folder by its address. In a shared drive this does not happen.