We are now verified! Husqy is now a verified bot in Discord making us visible in the app discovery and enabling bigger trust to users!
Want to help us translate the Husqy responses? We can't do it without you! Please visit our translations repo!
Skip to main content

Husqy API tags module

General

Endpoints related to general Husqy Modules Tags.

GET - /modules/tags/

Home endpoint for the Modules Tags Husqy API. Returns only success message displaying that it is the Modules Tags Husqy API route.

DELETE - /modules/tags/delete

Delete all settings of the tags module for a specified guild.

Body data (JSON):

fieldrequiredtypedescription
guild_idyesintegerThe ID of the guild to delete the settings from

Possible errors:

  • BadRequestError

Status

Endpoints related to the status of the module

GET - /modules/tags/status

Get the status of the tags module for the specified guild.

Query string parameters:

fieldrequiredtypedescription
guild_idyesintegerThe ID of the guild to check the status of

Possible errors:

  • BadRequestError
  • SettingsError
POST - /modules/tags/enable

Endpoint to enable the tags module for the specified guild.

Body data (JSON):

fieldrequiredtypedescription
guild_idyesintegerThe ID of the guild to enable the tags module for

Possible errors:

  • BadRequestError
  • SettingsError
  • ModuleEnabledError
  • DatabaseError
POST - /modules/tags/disable

Endpoint to disable the tags module for the specified guild.

Body data (JSON):

fieldrequiredtypedescription
guild_idyesintegerThe ID of the guild to disable the tags module for

Possible errors:

  • BadRequestError
  • SettingsError
  • ModuleDisabledError
  • DatabaseError

Entries

Endpoints related to tags entries

GET - /modules/tags/entries

Returns a list of tag entries in the specified guild.

Query string parameters:

fieldrequiredtypedescription
guild_idyesintegerThe ID of the guild to get the tag entries from
pagenointegerThe page number to get (default = 1)
page_sizenointegerThe amount of entries to return in one page (default = 10)

Possible errors:

  • BadRequestError
  • SettingsError
  • ModuleDisabledError
  • InternalServerError
  • DatabaseError
POST - /modules/tags/entries

Endpoint to create a new tag entry in a guild.

Body data (JSON):

fieldrequiredtypedescription
guild_idyesintegerThe ID of the guild to create the tag in
owner_idyesintegerThe ID of the owner of the tag
contentyesstringThe content of the tag
namesyeslistA list of names for the tag
visibilityyesstringThe visibility setting for the tag. Can be "Public" or "Private"
application_idyeslistCan be None. The application to respond to
tokenyeslistCan be None. The token of the application to respond

Possible errors:

  • BadRequestError
  • SettingsError
  • ModuleDisabledError
  • InternalServerError
  • DatabaseError
GET - /modules/tags/entry/{tag_id}

Returns the details of tag entry in the specified guild.

Query string parameters:

fieldrequiredtypedescription
guild_idyesintegerThe ID of the guild to get the tag entry details from

Possible errors:

  • BadRequestError
  • SettingsError
  • ModuleDisabledError
  • InternalServerError
DELETE - /modules/tags/entry/{tag_id}

Endpoint to delete a tag entry in a guild.

Body data (JSON):

fieldrequiredtypedescription
guild_idyesintegerThe ID of the guild to delete the tag in
application_idyeslistCan be None. The application to respond to
tokenyeslistCan be None. The token of the application to respond

Possible errors:

  • BadRequestError
  • SettingsError
  • ModuleDisabledError
  • InternalServerError
  • DatabaseError
  • Unprocessable Entity
{
"success": False,
"data": {},
"error": {
"code": 422,
"message": "Unprocessable Entity! {reason}",
},
},
PUT - /modules/tags/entry/{tag_id}

Endpoint to update a tag entry in a guild.

Body data (JSON):

fieldrequiredtypedescription
guild_idyesintegerThe ID of the guild to delete the tag in
namesyeslistThe new list of names for the tag. All other names will be deleted
owner_idyesintegerThe new ID of the owner
visibilityyesstringThe new visibility of the tag. Can be "Public" or "Private"
contentyesstringThe new content of the tag
application_idyeslistCan be None. The application to respond to
tokenyeslistCan be None. The token of the application to respond

Possible errors:

  • BadRequestError
  • SettingsError
  • ModuleDisabledError
  • InternalServerError
  • DatabaseError
  • Unprocessable Entity
{
"success": False,
"data": {},
"error": {
"code": 422,
"message": "Unprocessable Entity! {reason}",
},
},
POST - /modules/tags/entry/{tag_id}/send
danger

Do not use this endpoint yourself! Husqy will send tag content automatically when the command is executed.

Endpoint to post the tag to a channel.

Body data (JSON):

fieldrequiredtypedescription
guild_idyesintegerThe ID of the guild to delete the tag in
channel_idyesintegerThe ID of the channel where the /tags send command is executed. This channel will also be used for the channel variables
user_mention_idyesintegerCan be None. The ID of the user to use for the user variables
application_idyesintegerThe ID of the application interaction
tokenyesintegerThe token of the interaction

Possible errors:

  • BadRequestError
  • SettingsError
  • ModuleDisabledError
  • Unprocessable Entity
{
"success": False,
"data": {},
"error": {
"code": 422,
"message": "Unprocessable Entity! {reason}",
},
},
POST - /modules/tags/entry/{tag_id}/preview
danger

Do not use this endpoint yourself! Husqy will send tag content automatically when the preview button is used in the dashboard.

Endpoint to post the tag to a channel to preview.

Body data (JSON):

fieldrequiredtypedescription
guild_idyesintegerThe ID of the guild to delete the tag in
channel_idyesintegerThe ID of the channel where the preview message will be located. This channel will also be used for the channel variables
user_idyesintegerCan be None. The ID of the user to use for the user variables

Possible errors:

  • BadRequestError
  • SettingsError
  • ModuleDisabledError
  • Unprocessable Entity
{
"success": False,
"data": {},
"error": {
"code": 422,
"message": "Unprocessable Entity! {reason}",
},
},

Privacy

Endpoints related to privacy and the tags module

GET - /modules/tags/privacy/get-user-entries
danger

Do not use this endpoint yourself! This endpoint will be used by Husqy's Privacy configurator (/privacy) command.

Endpoint to get the amount of references in tags to your user.

Query string parameters:

fieldrequiredtypedescription
guild_idyesintegerThe ID of the guild to get the specified references in
privacy_member_idyesintegerThe ID of the member who wants to check their references

Possible errors:

  • BadRequestError
  • ForbiddenError
  • InternalServerError
DELETE - /modules/tags/privacy/delete-user-entries
danger

Do not use this endpoint yourself! This endpoint will be used by Husqy's Privacy configurator (/privacy) command.

Endpoint to delete the references in tags to your user.

Body data (JSON):

fieldrequiredtypedescription
guild_idyesintegerThe ID of the guild to delete the specified references in
privacy_member_idyesintegerThe ID of the member who wants to remove their references

Possible errors:

  • BadRequestError
  • ForbiddenError
  • InternalServerError