# Discourse Audio Message

**URL:** https://meta.discourse.org/t/discourse-audio-message/270432
**Category:** Development
**Created:** [July 3, 2023, 7:55pm UTC](https://meta.discourse.org/t/discourse-audio-message/270432 "2023-07-03T19:55:15Z")
**Posts on this page:** 20
**Page:** 1

<div class="post-metadata">

### Author: ![peter.be](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/peter.be/32/314243_2.png) [@peter.be](https://meta.discourse.org/u/peter.be)
#### Post date: [July 3, 2023, 7:55pm UTC](https://meta.discourse.org/t/discourse-audio-message/270432/1 "2023-07-03T19:55:15Z")

</div>

| | | |
| --- | --- | --- |
| ℹ | **Summary** | **Discourse Audio Message** allows users to directly record and attach audio messages to their posts. |
| 🛠 | **Repository Link** | [https://github.com/pbenkoe/discourse-audio-message](https://github.com/pbenkoe/discourse-audio-message) |
| 📖 | **Install Guide** | [How to install plugins in Discourse](https://meta.discourse.org/t/install-plugins-in-discourse/19157) |

This plugin was developed with the help of ChatGPT, as my background in backend/javascript development is limited.

The implementation is very basic, but I hope it will help some people and maybe it can serve as a foundation to develop it further.

Make sure to check the installation instructions on the Github page.

---

<div class="post-metadata">

### Author: ![Canapin](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/canapin/32/119591_2.png) [@Canapin](https://meta.discourse.org/u/Canapin)
#### Post date: [July 3, 2023, 8:04pm UTC](https://meta.discourse.org/t/discourse-audio-message/270432/2 "2023-07-03T20:04:24Z")

</div>

Hi, thanks for publishing your work. 🙂

It’s in the wrong category, though, and should go to #Customization > Plugin. Since you explained you don’t have particular knowledge in coding plugins and relied on chatGPT for some parts, I’ll ensure the code is properly written before moving it to this category.

Also, does it do anything that [Voice Recorder Component](https://meta.discourse.org/t/voice-recorder-component/215621) doesn’t already do?

---

<div class="post-metadata">

### Author: ![peter.be](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/peter.be/32/314243_2.png) [@peter.be](https://meta.discourse.org/u/peter.be)
#### Post date: [July 3, 2023, 8:09pm UTC](https://meta.discourse.org/t/discourse-audio-message/270432/3 "2023-07-03T20:09:50Z")

</div>

> [@Canapin](#):
>
> It’s in the wrong category, though, and should go to #plugin::category. Since you explained you don’t have particular knowledge in coding plugins and relied on chatGPT for some parts, I’ll ensure the code is properly written before moving it to this category.

Yes, please have a look and see if it checks out, and adjust the forum category as necessary 🙏

> [@Canapin](#):
>
> Also, does it do anything that [Voice Recorder Component](https://meta.discourse.org/t/voice-recorder-component/215621) doesn’t already do?

While I never tried it myself, based on the thread I assumed it doesn’t work properly and decided to develop a little plugin myself…

---

<div class="post-metadata">

### Author: ![Canapin](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/canapin/32/119591_2.png) [@Canapin](https://meta.discourse.org/u/Canapin)
#### Post date: [July 3, 2023, 8:17pm UTC](https://meta.discourse.org/t/discourse-audio-message/270432/4 "2023-07-03T20:17:18Z")

</div>

> [@peter.be](#):
>
> I assumed it doesn’t work properly

I tried it, and it currently doesn’t work indeed. On paper, what you are achieving with your plugin should be doable with a theme component (assuming [Voice Recorder Component](https://meta.discourse.org/t/voice-recorder-component/215621) does more or less the same thing), which is way easier to install.

Another example of a plugin that was rewritten as a theme component:

> [@Discourse Video Upload Plugin with YouTube and Vimeo](https://meta.discourse.org/t/discourse-video-upload-plugin-with-youtube-and-vimeo/168569):
>
> Note: This plugin is available as a theme component which enables a much easier installation. The plugin in this post is not actively supported, it is recommended to use the theme component : [Video Upload to YouTube and Vimeo using Theme Component](https://meta.discourse.org/t/video-upload-to-youtube-and-vimeo-using-theme-component/170079) Summary: Allows users on a Discourse forum to upload videos to Vimeo and YouTube directly from the Discourse composer. link GitHub: [GitHub - xomads/discourse-video-upload](https://github.com/xomads/discourse-video-upload)arrow_right Install: Follow the [plugin installation guide](https://meta.discourse.org/t/install-a-plugin/19157). Features All…

> [@Video Upload to YouTube and Vimeo using Theme Component](https://meta.discourse.org/t/video-upload-to-youtube-and-vimeo-using-theme-component/170079):
>
> This new theme component enables video uploads from the Discourse composer to YouTube and Vimeo. For those already familiar with [the plugin I developed recently](https://meta.discourse.org/t/discourse-video-upload-plugin-with-youtube-and-vimeo/168569), the same is now available in this Theme Component which can be added to any theme. This makes for a much easier installation and works in exactly the same way as the plugin. Features All forum members can upload videos to Vimeo or YouTube (admins can choose to enable either or both). Admins can control the view and embed privacy of th…

---

<div class="post-metadata">

### Author: ![peter.be](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/peter.be/32/314243_2.png) [@peter.be](https://meta.discourse.org/u/peter.be)
#### Post date: [July 3, 2023, 8:18pm UTC](https://meta.discourse.org/t/discourse-audio-message/270432/5 "2023-07-03T20:18:47Z")

</div>

Thank you, I’ll look into it.

---

<div class="post-metadata">

### Author: ![denvergeeks](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/denvergeeks/32/327671_2.png) [@denvergeeks](https://meta.discourse.org/u/denvergeeks)
#### Post date: [July 3, 2023, 9:50pm UTC](https://meta.discourse.org/t/discourse-audio-message/270432/6 "2023-07-03T21:50:11Z")

</div>

This Audio Message Recording plugin is working perfectly on my Discourse. Thank You @peter.be !!!

---

<div class="post-metadata">

### Author: ![denvergeeks](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/denvergeeks/32/327671_2.png) [@denvergeeks](https://meta.discourse.org/u/denvergeeks)
#### Post date: [July 3, 2023, 10:17pm UTC](https://meta.discourse.org/t/discourse-audio-message/270432/7 "2023-07-03T22:17:20Z")

</div>

FYI there is some discussion here about Plugin vs Theme Component…

> [@Plugin vs. theme component](https://meta.discourse.org/t/plugin-vs-theme-component/240908):
>
> Continuing the discussion from [Thumbs up, twice](https://meta.discourse.org/t/thumbs-up-twice/240867/4): Sorry, I didn’t try search — I’m a horrible person. But if out there is a plugin and a theme component and those do (almost) same thing what is the most important difference between those two? A plugin needs rebuilding, of course, but is there some other reasons why other is better choice than other?

---

<div class="post-metadata">

### Author: ![merefield](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/merefield/32/176214_2.png) [@merefield](https://meta.discourse.org/u/merefield)
#### Post date: [July 4, 2023, 6:46am UTC](https://meta.discourse.org/t/discourse-audio-message/270432/8 "2023-07-04T06:46:22Z")

</div>

> [@peter.be](#):
>
> While I never tried it myself, based on the thread I assumed it doesn’t work properly and decided to develop a little plugin myself…

It would have been better to PR a fix?

---

<div class="post-metadata">

### Author: ![denvergeeks](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/denvergeeks/32/327671_2.png) [@denvergeeks](https://meta.discourse.org/u/denvergeeks)
#### Post date: [August 2, 2023, 2:47am UTC](https://meta.discourse.org/t/discourse-audio-message/270432/9 "2023-08-02T02:47:07Z")

</div>

Here is a Vimeo demonstrating usage of this plugin… (and BTW it also works in mobile 👏)

[![](https://global.discourse-cdn.com/meta/original/4X/c/5/2/c52e6ed7ec1c40a24d8d9e9b6fa02df9256b07b7.jpeg "Discourse Audio Message Plugin Demo - 8/1/2023") ](https://vimeo.com/850772121)

---

<div class="post-metadata">

### Author: ![davidkingham](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/davidkingham/32/119528_2.png) [@davidkingham](https://meta.discourse.org/u/davidkingham)
#### Post date: [August 13, 2023, 3:49pm UTC](https://meta.discourse.org/t/discourse-audio-message/270432/10 "2023-08-13T15:49:22Z")

</div>

FYI this plugin breaks the tag groups page on my site. The entire list of tag groups disappears and you cannot modify any of the tag groups. Removed this plugin and the issue went away…

---

<div class="post-metadata">

### Author: ![JammyDodger](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jammydodger/32/254611_2.png) [@JammyDodger](https://meta.discourse.org/u/JammyDodger)
#### Post date: [August 13, 2023, 3:53pm UTC](https://meta.discourse.org/t/discourse-audio-message/270432/11 "2023-08-13T15:53:20Z")

</div>

I’ve slipped this over to #Development while there’s still some discussion over the development aspects of it. 👍

---

<div class="post-metadata">

### Author: ![merefield](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/merefield/32/176214_2.png) [@merefield](https://meta.discourse.org/u/merefield)
#### Post date: [August 13, 2023, 4:46pm UTC](https://meta.discourse.org/t/discourse-audio-message/270432/12 "2023-08-13T16:46:10Z")

</div>

Guys, it’s great fun to have a go at writing a plugin no-doubt and a very useful learning experience, and even more fun seeing if ChatGPT can help you write it …

… but deploying a plugin to Production and formally sharing it with the public does put the onus on you to support it going forward.

Relying on ChatGPT is all well and good as a productivity assistant but really you need to understand every line of code yourself.

I wouldn’t have a big problem with any of that if we hadn’t already had a Theme Component covering this functional space (albeit not currently functioning correctly)

Deploying a plugin to take its place is a step backwards as you would always want to deploy something as a Theme Component if at all possible so that it can be used more widely by more kinds of installs, are less invasive, and much quicker to deploy and remove.

You need to have a _very_ good reason to revert to using a Plugin (and that reason may exist but would be good to elaborate on and justify).

I still think as a community we should aim to maintain existing assets when they break rather than creating new ones (unless of course, like the Guest Gate Component, there’s a chance to create a Theme Component instead, which would be a worthwhile improvement)

To that end efforts would have been better directed at PRing to imho:

> [@Voice Recorder Component](https://meta.discourse.org/t/voice-recorder-component/215621):
>
> This is a working theme component based on the existing (broken) [voice recording plugin](https://meta.discourse.org/t/voice-recording-plugin/91885). The functionality is the same. Please make sure you’ve added mp3 to authorized extensions. hammer_and_wrenchRepository [GitHub - paviliondev/discourse-voice-recorder: Add voice recordings to Discourse posts · GitHub](https://github.com/paviliondev/discourse-voice-recorder)questionInstall Guide [How to install a theme or theme component](https://meta.discourse.org/t/how-do-i-install-a-theme-or-theme-component/63682)open_bookNew to Discourse Themes? [Beginner’s guide to using Discourse Themes](https://meta.discourse.org/t/beginners-guide-to-using-discourse-themes/91966)

I suspect the main reason that no longer works is because the original maintainer is too busy on other projects, but there is nothing stopping anyone contributing to the repo to fix it, has anyone tried?

There’s a limit to the amount of time members of Pavilion can devote to the numerous public contributions we’ve made over the years and the community really needs to pick up some of the load.

/rant over

---

<div class="post-metadata">

### Author: ![Jagster](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jagster/32/192154_2.png) [@Jagster](https://meta.discourse.org/u/Jagster)
#### Post date: [August 13, 2023, 5:03pm UTC](https://meta.discourse.org/t/discourse-audio-message/270432/13 "2023-08-13T17:03:57Z")

</div>

> [@merefield](#):
>
> You need to have a _very_ good reason to revert to using a Plugin

Perhaps because it works? And…

> [@merefield](#):
>
> I still think as a community we should aim to maintain existing assets when they break

That never happened.

From dev point of view I totally understad you. But as an example of end users I would say plugin vs. component is not that big question, because we (or I am) upgrading constantly anyway, and all that matters is way to get job done.

We don’t need applications to record and upload audio. We have devices that can do it (anyway, almost because Apple still dislike MP3), but it is not very streamlined workflow. One button is, no matter if it comes from plugin or component.

And yes. I prefer components too.

---

<div class="post-metadata">

### Author: ![merefield](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/merefield/32/176214_2.png) [@merefield](https://meta.discourse.org/u/merefield)
#### Post date: [August 13, 2023, 5:07pm UTC](https://meta.discourse.org/t/discourse-audio-message/270432/14 "2023-08-13T17:07:22Z")

</div>

> [@Jagster](#):
>
> From dev point of view I totally understad you. But as an example of end users I would say plugin vs. component is not that big question, because we (or I am) upgrading constantly anyway, and all that matters is way to get job done.

Those who are hosted at lower price points are often restricted to Theme Components for customisation, and that’s almost certainly a significantly larger population, so by switching to a plugin you are cutting out a lot of sites.

Of course you and I don’t have this particular restriction.

---

<div class="post-metadata">

### Author: ![Jagster](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jagster/32/192154_2.png) [@Jagster](https://meta.discourse.org/u/Jagster)
#### Post date: [August 13, 2023, 5:10pm UTC](https://meta.discourse.org/t/discourse-audio-message/270432/15 "2023-08-13T17:10:14Z")

</div>

That’s true. Those are cases I don’t remember ever. But they have limited access anyway. So such situation is just another more (which one should avoid if possible, though),

---

<div class="post-metadata">

### Author: ![Lilly](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/lilly/32/575047_2.png) [@Lilly](https://meta.discourse.org/u/Lilly)
#### Post date: [August 13, 2023, 5:11pm UTC](https://meta.discourse.org/t/discourse-audio-message/270432/16 "2023-08-13T17:11:31Z")

</div>

> [@Jagster](#):
>
> From dev point of view I totally understad you. But as an example of end users I would say plugin vs. component is not that big question, because we (or I am) upgrading constantly anyway, and all that matters is way to get job done.

it is actuallly a very big deal since so many instances are hosted, and plugins are also further limited by hosting tiers. theme components have some limitations but also offer much more flexibility and ease of administration for those who are not self-hosted.

---

<div class="post-metadata">

### Author: ![Lilly](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/lilly/32/575047_2.png) [@Lilly](https://meta.discourse.org/u/Lilly)
#### Post date: [August 13, 2023, 5:13pm UTC](https://meta.discourse.org/t/discourse-audio-message/270432/17 "2023-08-13T17:13:05Z")

</div>

> [@Jagster](#):
>
> So such situation is just another more (which one should avoid if possible, though),

maybe i am misunderstanding you (language issues) but i disagree - hosting is a very viable option and solution for many forums.

---

<div class="post-metadata">

### Author: ![merefield](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/merefield/32/176214_2.png) [@merefield](https://meta.discourse.org/u/merefield)
#### Post date: [August 13, 2023, 5:16pm UTC](https://meta.discourse.org/t/discourse-audio-message/270432/18 "2023-08-13T17:16:41Z")

</div>

Anyway this wasn’t meant to be a big pile on and I’m really pleased @peter.be you’ve got into this space and you are sharing your work, but perhaps you can consider these broader points 👍

---

<div class="post-metadata">

### Author: ![peter.be](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/peter.be/32/314243_2.png) [@peter.be](https://meta.discourse.org/u/peter.be)
#### Post date: [August 13, 2023, 5:46pm UTC](https://meta.discourse.org/t/discourse-audio-message/270432/19 "2023-08-13T17:46:54Z")

</div>

Robert, thank you for bringing up your concerns.

When I decided to code my own solution (since none of the existing ones work atm), I didn’t know about the pros and cons of theme components vs plugins. It would be great if the how-to on plugin development contained a disclaimer, maybe? ([Developing Discourse Plugins - Part 1 - Create a basic plugin](https://meta.discourse.org/t/developing-discourse-plugins-part-1-create-a-basic-plugin/30515))

I really just needed a simple solution to facilitate the audio recording workflow. If you, as a veteran in this space, feel inspired to transform the plugin into a theme component, I’d be happy to assist you and answer questions about the source code of the plugin.

If you don’t, I might be able to come back to this eventually, I just can’t say when I’ll have the time 🙏

---

<div class="post-metadata">

### Author: ![denvergeeks](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/denvergeeks/32/327671_2.png) [@denvergeeks](https://meta.discourse.org/u/denvergeeks)
#### Post date: [August 13, 2023, 6:14pm UTC](https://meta.discourse.org/t/discourse-audio-message/270432/20 "2023-08-13T18:14:07Z")

</div>

> [@merefield](#):
>
> You need to have a _very_ good reason to revert to using a Plugin (and that reason may exist but would be good to elaborate on and justify).

I have tried to repair the broken Theme Component version, but my skills are apparently not yet up to the task.

I was, however, able to fix and improve some things in the Plugin, so doing that was fun and of course I learned some things too, which is always the best reward!

(i.e. I submitted my very first [PR](https://github.com/pbenkoe/discourse-audio-message/pull/2) on Github!)

I’ll keep at it, because I do agree about the advantages of Theme Component over a Plugin (and it’s always most preferable to have both options, because Plugins do still have _some advantages_ over TCs!)

[Next page](https://meta.discourse.org/t/discourse-audio-message/270432.md?page=2)
