5
submitted 2 years ago by sylverstream@lemmy.nz to c/asklemmy@lemmy.ml

I'm a moderator in one of the Lemmy communities and want to set up a bot to post a message every day. I only found this; is that the best way? I'm a developer, so I'm confident I can set it up on a locally hosted server, but then other moderators won't be able to edit it. Is there a better way to do this?

top 10 comments
sorted by: hot top controversial new old
[-] Sal@mander.xyz 3 points 2 years ago

Is this for a single community? Maybe you can host a simple password-protected site where the moderators can modify the message.

@fossilesque@mander.xyz is developing a plant id bot for !plantid@mander.xyz, perhaps they can explain to you how they are doing that.

[-] fossilesque@mander.xyz 3 points 2 years ago

Yeah, happy to share the code. It's python + docker. You'll probably be able to just simply it!

[-] Julius_Seizures@lemmy.world 3 points 2 years ago

I'd love to take a peek as well if you don't mind.

[-] sylverstream@lemmy.nz 3 points 2 years ago

Yeah it's for a single community, stopdrinking. It's for the daily check in post.

[-] PriorProject@lemmy.world 3 points 2 years ago* (last edited 2 years ago)

I haven't used it, but lemmybot or or the lower-level https://github.com/LemmyNet/lemmy-js-client, which is a pure client with no bot features are what I'm aware of.

I'd make sure to evaluate the API changes planned for v18 of Lemmy though. There's a major shift away from the websockets API that's about to land, and it's quite possible that you'd build a bot to find out it's broken a week later and needs to be adapted for a totally different API.

[-] retiolus@lemmy.cat 2 points 2 years ago

I'm building Lemmy.py, a Python wrapper for the Lemmy API, I made a post about it here: https://lemmy.cat/post/4479

[-] sylverstream@lemmy.nz 1 points 2 years ago

Thank you. How would you recommend to handle things like daily posts and giving all mods the ability to edit? Especially mods without programming experience?

[-] retiolus@lemmy.cat 1 points 2 years ago

Please explain in detail how you would like the bot to work and what features it should have.

One post a day. The same post every day? A default motd that you can edit but as long as you don't change it, it publishes every day? Should the time be configurable? Etc...?

[-] CapillaryUpgrade 1 points 2 years ago

You could use gihtub/gitlab to host the code for the bot and allow editing that way?

You could probably use their CI/CD infrastructure to run the bot itself, too!

[-] sylverstream@lemmy.nz 2 points 2 years ago

Yeah was thinking about that as well, sounds like a plan. Thanks for the tip.

this post was submitted on 17 Jun 2023
5 points (100.0% liked)

Asklemmy

44064 readers
744 users here now

A loosely moderated place to ask open-ended questions

Search asklemmy ๐Ÿ”

If your post meets the following criteria, it's welcome here!

  1. Open-ended question
  2. Not offensive: at this point, we do not have the bandwidth to moderate overtly political discussions. Assume best intent and be excellent to each other.
  3. Not regarding using or support for Lemmy: context, see the list of support communities and tools for finding communities below
  4. Not ad nauseam inducing: please make sure it is a question that would be new to most members
  5. An actual topic of discussion

Looking for support?

Looking for a community?

~Icon~ ~by~ ~@Double_A@discuss.tchncs.de~

founded 5 years ago
MODERATORS