Skip to content

Commit ceb83e1

Browse files
authored
Create get_script.md
1 parent 366675e commit ceb83e1

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

doc/md/get_script.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# How to get Google Apps Script
2+
We have to 2 method to get the Google Apps Script.
3+
1. Copy the script from
4+
here: https://github.com/PerfecXX/MicroPython-GoogleSheet/blob/main/script.gs
5+
2. Use the gen_scriptFile() function to generate the script file.
6+
```python
7+
from ggsheet import MicroGoogleSheet
8+
9+
# Google Sheet Credential
10+
google_sheet_url = "https://docs.google.com/spreadsheets/d/xxxxxxxxx/edit#gid=0"
11+
google_sheet_name = "Sheet1"
12+
13+
ggsheet = MicroGoogleSheet(google_sheet_url,google_sheet_name)
14+
ggsheet.gen_scriptFile()
15+
```
16+
After running the script, it will be saved at root (/) on your ESP32 or ESP8266, then copied to Google Apps Script.

0 commit comments

Comments
 (0)