One of the major feature requests after the initial 0.1.0 release was to add support for multiple invite links and the ability to create links and role associations directly from discord.
There are two major feature requests here that go kind of hand in hand.
Support for tracking multiple invite codes.
[ ] The database is currently keying off of the projectID + guildID this is an issue, because it will result in collisions in a multi invite structure. We need to key off of projectID + guildID + inviteID.
[ ] Retrieval of invite metadata from GCP datastore will need to be updated to getAll instead of retrieving a single row by key.
[ ] All usages of getStoredInviteMetadata will need to be updated to work with an array of inviteMetadata structs.
[ ] A mapping between invite code and the roles that should be added when it increments will need to be created.
Support for defining invite code and role associations from discord.
[ ] Add handler for listen to discord messages.
[ ] Add a config for defining the channels to listen to.
[ ] Define switch case for actions invoked by users. This should be handled in a separate file from the main Ohms one.
[ ] The syntax for requesting a new invite code role association is as follows: <listen-key>createinvite role1,role2,role3 [channel:channelID] [alias:alias] The listen-key is a configurable character that starts all command intended for Ohms. createinvite is the action name. role1,role2,etc is a comma separated list of roleIDs, if possible make it accept role names or role IDs. channel is an optional parameter that can be pass to set the channel association. Its value is the channel ID. alias is an optional name for the new invite to roles mapping.
[ ] In the action method for creating a new invite code with role associations perform a permission check to see if the user has role terabyte.
[ ] Add an action route for dumping role names with their ids. Ohms should respond to the user via a DM.
One of the major feature requests after the initial 0.1.0 release was to add support for multiple invite links and the ability to create links and role associations directly from discord.
There are two major feature requests here that go kind of hand in hand.
Support for tracking multiple invite codes.
[ ] The database is currently keying off of the projectID + guildID this is an issue, because it will result in collisions in a multi invite structure. We need to key off of projectID + guildID + inviteID.
[ ] Retrieval of invite metadata from GCP datastore will need to be updated to
getAll
instead of retrieving a single row by key.[ ] All usages of
getStoredInviteMetadata
will need to be updated to work with an array of inviteMetadata structs.[ ] A mapping between invite code and the roles that should be added when it increments will need to be created.
Support for defining invite code and role associations from discord.
[ ] Add handler for listen to discord messages.
[ ] Add a config for defining the channels to listen to.
[ ] Define switch case for actions invoked by users. This should be handled in a separate file from the main Ohms one.
[ ] The syntax for requesting a new invite code role association is as follows:
<listen-key>createinvite role1,role2,role3 [channel:channelID] [alias:alias]
Thelisten-key
is a configurable character that starts all command intended for Ohms.createinvite
is the action name.role1,role2,etc
is a comma separated list of roleIDs, if possible make it accept role names or role IDs.channel
is an optional parameter that can be pass to set the channel association. Its value is the channel ID.alias
is an optional name for the new invite to roles mapping.[ ] In the action method for creating a new invite code with role associations perform a permission check to see if the user has role
terabyte
.[ ] Add an action route for dumping role names with their ids. Ohms should respond to the user via a DM.