Output txt file from Gdrive?

I’m sorry I’m new to this but, Is it possible for nightbot to display a .txt file from gdrive?
The .txt file only contains a 6 letters/numbers combination. I enabled the file to be seen by anyone who has a link then I tried to use $urlfetch but I’m only getting “Remote Server Returned Code 429” error. Thank you so much in advance.

The file would have to return plain text for it to work properly.

Yeah, It’s actually just a plain text, and I wanted it to be displayed as plain text too.

$(urlfetch https://drive.google.com/file/d/blahblahblah/view?usp=sharing)

This is my code but It’s just returning error code 429

How often are you attempting to call this cause the error code means your sending to many requests

Hey @Boibot!

Why not use Pastebin instead?
Create an account, create your paste, save it with the Expiration date set to Never, and the Exposure as Unlisted.
After that add raw/ before the pasteID and use that link in the $(urlfetch):

$(urlfetch https://pastebin.com/raw/XXXXXXXX)

If you really want to use Google Drive, you’ll have to use their API, and at first glance I didn’t see any way to fetch the data in a .txt file, although it would be possible with a Google Doc.


The error code 429 doesn’t tell the whole story here, there are various ways you can get such error, and I believe it’s because you don’t use their API. If you try to get the sharing menu again, you’ll likely get an error telling you that you’re breaking their terms of service by trying to access the file through a bot without their API.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.