Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update run.md to use Desktop App for OAuth Client ID Application Type #998

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions docs/run.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@

To use `clasp run`, you need to complete 5 steps:

- Set up the **Project ID** in your `.clasp.json` if missing.
- Create an **OAuth Client ID** (Other). Download as `creds.json`.
- Set up a **Project ID** in your `.clasp.json` if missing.
- Create an **OAuth Client ID** (Desktop App). Download as `creds.json`.
- `clasp login --creds creds.json` with this downloaded file.
- Add the following to `appsscript.json`:
```json
Expand Down Expand Up @@ -73,7 +73,8 @@ Many Apps Script functions require special OAuth Scopes (Gmail, Drive, etc.).
To run functions that use these scopes, you must add the scopes to your Apps Script manifest and `clasp login` again.

- `clasp open`
- `File > Project Properties > Scopes`
- Add these scopes to your `appsscript.json`.
- At the left, click **Overview**.
- View the scopes under "Project OAuth Scopes."
- Add these scopes to your `appsscript.json` in the `oauthScopes` property array.
- Log in again: `clasp login --creds creds.json`. This will add these scopes to your credentials.
- `clasp run sendMail`