imptype / serverless-chatgpt-discord-bot

Serverless ChatGPT Discord bot hosted on Deta Space.
MIT License
18 stars 0 forks source link

Please update the app - Developer mode not available to new users #3

Open BadToxic opened 1 week ago

BadToxic commented 1 week ago

[Edit 2] I wanted to try it by building the app myself but I can't, because it need to activate the developer mode. After searching about that, I had to learn, that the developer mode was disabled completely in January 2024 for new members and one can no longer apply for it.

image From their official discord.

So if you still have the rights, I would kindly ask you to update the app.

====

[Edit 1] Sorry, didn't see there already were two issues with that same problem. But this means it can only work when not using the space app from the app's discovery page but building it myself? Can you not update (or replace) the space app?

====

I followed your readme to run it online with installing the space app from the app's discovery page. When I reach the point to visit /bot/api/dash/ to register the slash commands for the first time I only get the pop up message from the browser that says "undefined" and see an empty commands table.

The browser (Chrome & Firefox) console says

https://chatgpt-1-w***.deta.app/api/sync/MT***mw 404 (Not Found)
(anonymous) @ MT***mw:153
runtime:30 space runtime: successfully registered the service worker with scope: https://chatgpt-1-w***.deta.app/

I checked all keys, IDs, token twice. I even regenerated the token. Also I wonder why there are two environment variables fields for the token - I filled both with the same token: DISCORD_BOT_TOKEN (bot) and DISCORD_BOT_TOKEN (main)

Can you please help me?

imptype commented 1 week ago

The version on Space Discovery was indeed outdated. I released a new version just now.

There's 2 environment keys for DISCORD_BOT_TOKEN because I wanted to demonstrate how to use different micros. bot and main are the name of 2 micros. Env vars are separate between micros. It is kind of pointless but still useful to know how to do it.

I also suggest you check out this newer guide that hosts on Vercel: https://github.com/imptype/BasicBot

BadToxic commented 1 week ago

I tried it with the new version exp-kQ7G via update and one time reinstalled - same result: "undefined" when opening https://chatgpt-1-g***.deta.app/bot/api/dash/MT***mw. And the console says GET https://chatgpt-1-g***.deta.app/api/sync/MT***mw 404 (Not Found) Does it work for you?

imptype commented 1 week ago

@BadToxic Try using the latest version on Space Discovery, I updated the entire repository to use the latest version of discohook. You'll also need to set a new environment variable in app settings called SYNC_PASSWORD and visit <micro_url>/api/dash to sync commands.