Tags
Save a named snippet of text and let anybody in the server call it back by name.
A tag is a piece of text with a name on it. Somebody types ,tag rules and the bot posts whatever
you saved under rules. That is the whole difference between this and an
autoresponder: an autoresponder fires because a message contains
a phrase, whether the person wanted it or not, while a tag only ever answers when somebody asks for
it by name. Use an autoresponder for the question you are tired of seeing; use a tag for the answer
you are tired of retyping.
Calling a tag needs no permission: every member can. Everything that creates, changes or inspects
one needs Manage Messages. Tags are prefix-only, so the examples below use the default ,
prefix; there is no slash form of this command.
Call a tag
,tag followed by a name posts that tag's text as a reply to whoever asked.
Syntax
,tag <name>
Example
,tag rules
Names are stored lowercased and looked up lowercased, so ,tag RULES and ,tag rules reach the
same one. ,t and ,tags are aliases of the whole command.
A name with no tag behind it does nothing at all: no error, no reply, no reaction. Silence here means "there is no such tag", not "the bot is down".
Save a tag
,tag add (alias create) takes the name, then everything after it
as the body.
Syntax
,tag add <name> <content>
Example
,tag add rules Read #rules before posting.
| Part | Means | Accepts |
|---|---|---|
<name> | what people will type after ,tag | one word; stored lowercased |
<content> | the text the tag posts | everything after that first word |
The name is one word, and the split is not negotiable: ,tag add server rules here makes a tag
called server whose body is rules here. If you want a two-word name, join it up: serverrules.
A name that already exists is refused rather than overwritten, so add can never quietly replace
somebody else's tag. Runs of spaces collapse to a single space when the body is saved; line breaks
survive, so a multi-line tag stays multi-line.
Know what a tag body can hold
A tag posts as plain text, and nothing in it is interpreted
Embed codes are not parsed here, so {title: Rules} posts as the
literal text {title: Rules}. Variables are not filled in either: {user} comes out as
{user}, braces and all. A tag is the exact characters you typed, every time anybody calls it.
Mentions inside a tag body are rendered but never notify anybody. The bot sends with mentions
switched off globally, so a tag containing @everyone, a role or a member reads as a mention in
Discord and pings nobody, including the person the reply is attached to. That is a safety property
worth knowing before you assume a tag is a way to alert a role.
Links, custom emoji and Discord's own markdown all behave the way they would in any message you typed yourself, because that is all this is.
Change what a tag says
,tag edit (alias e) replaces the body and leaves the name alone.
It follows exactly the same one-word-name split as add.
Syntax
,tag edit <name> <content>
Example
,tag edit rules Read #rules before posting, please.
There is no partial edit and no append: whatever you type becomes the entire new body.
Rename or delete a tag
,tag rename (alias re) changes the name and keeps the body.
Syntax
,tag rename <name> <new name>
Example
,tag rename rules serverrules
The new name is lowercased like any other. Unlike add, rename does not check whether the new
name is already taken, so renaming one tag onto the name of another leaves two rows answering to the
same word and only one of them reachable. Check with ,tag list first.
,tag remove (alias delete) deletes one. There is no
confirmation and no undo, and it only ever touches this server's tags.
Syntax
,tag remove <name>
Example
,tag remove rules
See what the server already has
,tag list pages through every tag in the server, ten to a page,
numbered, each with whoever created it. It shows the names, not the bodies.
Syntax
,tag list
,tag search (alias s) lists only the tags whose name
contains a word. The body is not searched, so this finds serverrules from rules but will not
find a tag that merely mentions rules in its text.
Syntax
,tag search <tag name>
Example
,tag search rule
,tag info (alias i) shows one tag's full body and names its
creator in the footer.
Syntax
,tag info <name>
Example
,tag info rules
,tag author answers the same question on its own, for when you
only want to know who to ask about a tag.
Syntax
,tag author <tag>
Example
,tag author rules
A tag outlives the person who made it. list and info fall back to a plain user ID once the
creator has left the server, rather than pretending a member who is gone is still around.
,tag help prints the command's own help card. It is the one
subcommand behind a gate: it needs premium or Server Premium. Every other part of tags is free,
and running ,tag with no arguments shows the same card to anybody.
Understand which names a subcommand takes first
A tag cannot shadow a command. Tags live entirely behind the ,tag command, so a tag called ban
is called with ,tag ban and has no effect whatsoever on ,ban. Nothing about tags changes how a
normal command is looked up.
The collision runs the other way. ,tag <word> checks the subcommands first, so a tag whose name
matches a subcommand or one of its aliases is shadowed by it. ,tag info runs the info subcommand
and never goes looking for a tag called info:
| Reserved | Because it is |
|---|---|
add, create | the create subcommand and its alias |
edit, e | the edit subcommand and its alias |
remove, delete | the delete subcommand and its alias |
rename, re | the rename subcommand and its alias |
info, i | the info subcommand and its alias |
search, s | the search subcommand and its alias |
author, list, help | subcommands with no alias |
add refuses a duplicate tag name, but it does not refuse these: you get a cheerful success
message and a tag its own name will not fetch. There is exactly one crack in that, and it is not one
to build on: the subcommand match is case-sensitive while the tag lookup is not, so ,tag Info
misses the subcommand, falls through to the plain tag lookup and posts the tag after all. A tag you
can only reach by capitalising it is a tag nobody will guess. Rename it, or pick a name that is not
also an instruction.
Because tags are a command and autoresponders are not, everything that governs commands governs
tags: ,command disable switches tag off, and
a channel or role restriction on it applies exactly as it would to any other command.
Common issues
,tag something does nothing. That is the "no such tag" answer. Names are one word and stored
lowercased, so check the spelling against ,tag list: a tag added
as server rules is really called server.
I made a tag and it will not come back. Check its name against the reserved list above. ,tag list will happily show a tag called info; ,tag info will always run the subcommand instead.
,tag Info does reach it, because the subcommand match is case-sensitive: treat that as a way to
read the tag while you rename it, not as how people should call it.
Only the first word of my tag name saved. Working as designed: the first word is the name and the rest is the body. Remove it and add it again with the name joined up.
A tag with @everyone in it is not pinging anybody. Also working as designed. The bot posts
with mentions disabled, so no tag can notify a person or a role no matter what it contains.
My tag prints {user} instead of a name. Tags do not run the variable pass and do not parse
embed codes. See Know what a tag body can hold. For text that
changes per person, you want an autoresponder or an
embed code somewhere that supports one.
,tag author will not tell me who made an old tag. It cannot report a creator who has left the
server. Run ,tag info instead: it falls back to the raw user ID,
which is still enough to search your audit log or ask around.
,tag edit says "Successfully renamed". It edited the body. The confirmation wording is wrong,
not the action: nothing was renamed.
A member says the tag exists but they cannot make one. Calling a tag is open to everybody; creating, editing, renaming, deleting and inspecting all need Manage Messages.
Nothing here fixed it. The shared common issues page works the same ground from the symptom end.