Discourse Staff Alias

Discourse Staff Alias

Discourse Staff Alias

Official staff alias plugin for Discourse.

Repo: https://github.com/discourse/discourse-staff-alias

The Discourse staff alias plugin allows you to reply, edit and create posts as an alias user.


  1. Under admin > settings , set the staff alias username for the staff alias plugin and enable the plugin by checking staff alias enabled .
  2. Under the composer’s actions drop down, staff users can choose to create topics or posts as the staff alias user.

Screenshot from 2020-06-29 09-32-07


Great idea for a plugin. I’d like to use this plugin to post as system .

Normally a post is written by staff, then ownership is transferred to system . I realize this alias already exists, but it is trusted by users and staff on our forum. Thanks for any tips or thoughts!

1 Like

The Staff Alias plugin seems to cause an error from the Discourse Github plugin if a Github link is included in a post that’s been created by the alias user. The error is Job exception: Validation failed: You can only edit a staff alias post as the staff alias user. Looking at the backtrace, it seems to happen here:


Should the Discourse system user be allowed to edit staff alias posts?


Fixed in https://github.com/discourse/discourse-staff-alias/commit/f463ac25b547a4670a90671d24511f44e60b1cc0 :slight_smile:


Seems to reject my choice of user on the basis that the user exists. Think that’s a bug:

1 Like

I’ll have a look at this but it might be tricky since I need to work out how the plugin would handle the changing of the staff alias user.

1 Like

Moderators have just tried out the feature on my forum.

They’re encountering “forbidden” error messages when posting the first time as staff alias. Annecdotally, one moderator was later able to post successfully when retrying, but another moderator retried with no success.

Nothing helpful in the logs I’m afraid

Processing by PostsController#create as */*
  Parameters: {"raw"=>"and again...", "unlist_topic"=>"false", "category"=>"4", "topic_id"=>"15371", "is_warning"=>"false", "whisper"=>"false", "archetype"=>"regular", "typing_duration_msecs"=>"1200", "composer_open_duration
_msecs"=>"27574", "featured_link"=>"", "shared_draft"=>"false", "draft_key"=>"topic_15371", "as_staff_alias"=>"true", "reply_to_post_number"=>"12", "nested_post"=>"true"}
Completed 403 Forbidden in 13ms (Views: 0.2ms | ActiveRecord: 0.0ms | Allocations: 2438)

I doubt it makes any difference but I have customised the text on my instance:

I’m unable to reproduce this locally so I’ll need more information to help you with the debugging. Was the ModTeam user created manually or via the staff_alias_username site setting? Are the users that were attempting to create the posts in the right groups that have been allowed via the staff_alias_allowed_groups site setting?

1 Like

Thanks for getting back to me on this.

Yes, the users are in the “team” group which is the one and only group set on staff_alias_allowed_groups.

The ModTeam user was created when I set staff_alias_username