mirror of
https://github.com/cpvalente/ontime.git
synced 2026-08-13 19:33:46 +00:00
use only sheets portion of google api
This commit is contained in:
@@ -5,6 +5,7 @@
|
||||
"version": "2.13.1",
|
||||
"exports": "./src/index.js",
|
||||
"dependencies": {
|
||||
"@googleapis/sheets": "^5.0.5",
|
||||
"body-parser": "^1.20.0",
|
||||
"cors": "^2.8.5",
|
||||
"dotenv": "^16.0.1",
|
||||
@@ -13,7 +14,6 @@
|
||||
"express-static-gzip": "^2.1.7",
|
||||
"express-validator": "^6.14.2",
|
||||
"google-auth-library": "^9.2.0",
|
||||
"googleapis": "^128.0.0",
|
||||
"lowdb": "^5.0.5",
|
||||
"multer": "^1.4.5-lts.1",
|
||||
"node-osc": "^9.0.2",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { OAuth2Client } from 'google-auth-library';
|
||||
import { readFile, writeFile } from 'fs/promises';
|
||||
import { google } from 'googleapis';
|
||||
import { sheets } from '@googleapis/sheets';
|
||||
import http from 'http';
|
||||
import { URL } from 'url';
|
||||
import { logger } from '../classes/Logger.js';
|
||||
@@ -55,7 +55,7 @@ class sheet {
|
||||
throw new Error('Got incorrect options to excel import', JSON.parse(options));
|
||||
}
|
||||
|
||||
const rq = await google.sheets({ version: 'v4', auth: sheet.client }).spreadsheets.values.get({
|
||||
const rq = await sheets({ version: 'v4', auth: sheet.client }).spreadsheets.values.get({
|
||||
spreadsheetId: sheetId,
|
||||
valueRenderOption: 'FORMATTED_VALUE',
|
||||
majorDimension: 'ROWS',
|
||||
|
||||
Reference in New Issue
Block a user