How can I view the source of a google apps script Library
Asked Answered
S

2

11

In the google apps script editor for google sheets, I can add a library created by others if I know the project key e.g. MKvHYYdYA4G5JJHj7hxIcoh8V4oX7X1M_ (a library for accessing the Twitter API)

But how can I view the source of that library?

Straub answered 13/8, 2015 at 16:42 Comment(1)
one way is to put a breakpoint before a library call, then step-into it. maybe there is a better way.Bessie
S
23

Just copy and paste in the URL:

https://script.google.com/d/(THE_SCRIPT_ID)/edit?usp=drive_web

Eg. https://script.google.com/d/MKvHYYdYA4G5JJHj7hxIcoh8V4oX7X1M_/edit?usp=drive_web

Scherman answered 13/8, 2015 at 20:16 Comment(4)
doesn't this throw the permission screen?Determinate
No Bryan P, it does not ask for permission or authorisation. Logically if the library is shared to the world without asking for login credentials or 'permission', Google would not throw the permission screen. If the library is NOT shared that way then it can not be used without express permission by the author/copyright-holdersFie
How do you get the script id / project key?Pentachlorophenol
@Pentachlorophenol You can get a script's ID by checking project properties under file. You need it to add it as a library in another script.Flashover
H
2

Not all libraries are open-source and have their source code available for viewing..... some libraries may be proprietary and only accessible to the owner or authorized users....!

Hacker answered 9/2, 2023 at 5:0 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.