Authentication Modes
Authentication Modes Overview
Comparison of all 5 supported authentication modes in nuxt-gsheet.
nuxt-gsheet automatically detects and supports 5 distinct authentication modes depending on your spreadsheet privacy and credential setup.
Comparison Matrix
| Mode | Credentials Needed | Public / Private | Read | Write | Quota Limit |
|---|---|---|---|---|---|
gviz | None | Public Only | Yes | No | Uncapped (Google Query API) |
csv | None | Public Only | Yes | No | Uncapped (Direct CSV export) |
appscript | Apps Script Web App URL | Public & Private | Yes | Yes | Free (Script Execution Quotas) |
apikey | GCP API Key | Public Only | Yes | No | Standard GCP API Limits |
service-account | GCP Service Account JSON | Private & Public | Yes | Yes | Standard GCP API Limits |
Automatic Detection Priority
If auth is not explicitly declared in nuxt.config.ts, nuxt-gsheet detects the active mode based on defined environment variables in this order:
appscript: Detected ifGSHEET_APPSCRIPT_URLis present.apikey: Detected ifGSHEET_API_KEYis present.service-account: Detected ifGSHEET_CLIENT_EMAILandGSHEET_PRIVATE_KEYare present.gviz/csv: Fallback mode if onlyGSHEET_SPREADSHEET_IDis present.