Copy Uploaded Files to Google Drive: Overview
Example: copy uploaded files to Google Drive
This page explains how to copy every file uploaded to AnyDB into Google Drive, once each, after the upload finishes, and gives the values both Zapier and Make need. For step-by-step instructions with screenshots, see the Zapier guide or the Make guide. The flow is the same in both tools:
- Trigger: AnyDB Updated Record, narrowed to records of type File whose file cell
A1changed. It fires once per upload, when the upload completes. - Download: call AnyDB's file download endpoint with the record from the trigger.
- Upload: send the downloaded file to Google Drive, named after the AnyDB record.
The trigger fields used here (Record Type, optional Record ID and Cell IDs) need AnyDB Zapier app 1.2.1 or later, and the matching update of the AnyDB Make app.
What you need
| Item | Where to get it |
|---|---|
| AnyDB URL | https://app.anydb.com (or your own AnyDB server) |
| AnyDB email | the email of the AnyDB user whose access the integration uses |
| AnyDB API key | the integration key in that user's Profile dialog. One key works for the Zapier app, the Make app and the download endpoint below |
| Team and Database | picked from the lists in the trigger |
| Google Drive | a Google Drive connection in Zapier or Make |
The integration only sees records and files that this AnyDB user is allowed to read.
Reference: values used in both tools
What the trigger sends. Each run receives one record. These are the keys used below:
| Key | Meaning | Example |
|---|---|---|
teamid | Team ID | <team id> |
adbid | Database ID | <database id> |
adoid | Record ID of the File record | <record id> |
name | Record name, which for a file is the file name with its extension | Invoice 2024.pdf |
cell_pos | the cell that changed | A1 |
object_url | link to the record in AnyDB | https://app.anydb.com/<team>/<db>/<record> |
Also sent: team_name, adb_name, type, created, updated, createdby_userid, createdby_displayname, updatedby_userid, updatedby_displayname, cell_key, cell_type and cell_value.
The download endpoint.
GET https://app.anydb.com/api/integrations/ext/download
| Query parameter | Value |
|---|---|
teamid | the trigger's teamid |
adbid | the trigger's adbid |
adoid | the trigger's adoid |
cellpos | A1 (the file cell of a File record) |
redirect | false returns the download link as JSON (used here). true answers with a redirect to the file |
| Header | Value |
|---|---|
X-ANYDB-EMAIL | your AnyDB email |
X-ANYDB-API-KEY | your AnyDB API key |
With redirect=false the response is JSON. The data property holds a short-lived, pre-signed link to the file. The link needs no credentials:
{ "status": "success", "data": "https://<storage-host>/<path>?X-Amz-Signature=..." }
Step-by-step guides with screenshots
- Upload files to Google Drive from AnyDB with Zapier: AnyDB Updated Record → Webhooks by Zapier GET → Google Drive Upload File.
- Upload files to Google Drive from AnyDB with Make: AnyDB Watch a record for updates → HTTP Make a request → HTTP Download a file → Google Drive Upload a File.
Troubleshooting
| Symptom | Cause and fix |
|---|---|
| The Zap or scenario does not run | Record Type must be File and Cell IDs A1. The AnyDB user must be able to read the uploaded file. |
| It runs twice per upload | Your AnyDB server predates the fix that ignores the upload's placeholder write. Ask your AnyDB administrator to update the server. |
| Make: The initial URL is allowed, but the redirect destination is not allowed by this connection | Use redirect=false with the two HTTP modules shown above. |
Make: [403] Request had insufficient authentication scopes at Google Drive | See the Google Drive permissions note above. |
Make: hooks.type: Value must not be empty when creating the trigger's webhook | Your Make account has an outdated copy of the AnyDB app. Refresh, or contact AnyDB support. |
| The download returns 401 or 403 | Check X-ANYDB-EMAIL and the API key, and that the user can read the record. |