2

Is there any plan to provide Google Apps Script capability for the "Files | Publish to the web..." menu item in a Google Document?

This has been asked before, but heck if I can find an answer. To be clear, I don't mean setting the sharing or viewability of the Document itself, I mean the thing where a web page representation of the Document with its own link is generated.

0

2 Answers 2

1

There is now a method for this, provided here.

First, add the service Drive API
Apps Script add Drive API service

var docId = "###"; // Please set this. Drive.Revisions.update({published: true, publishedOutsideDomain: true, publishAuto: true}, docId, 1); 
Sign up to request clarification or add additional context in comments.

Comments

0

It is not possible directly with GAS. However, using the Document List API and URLFetch with oAuth, you can, in theory make a document public on the web. Publish to the web option, per se, isn't available though.

Please see the following links for information and help

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.