Grabbing all data from a DataStore

Hello,

As of recent, I have been working on creating some commands that store data on individuals (mainly commands such as ban) with @evaera’s command-line Cmdr. Currently, I store this data in a regular DataStore (grabbed with <DataStoreService>:GetDataStore()), using a key which is just their UserId (if I recall correctly, I am not on studio as we speak).

Other admin systems, like Adonis, allow you to view all the bans via a banlist (or similar) command. So, my main question is, how would I go about getting all my data in one go?

For example, when a player is banned, there is probably a separate key that holds a table full of player names. Either that or they save all banned players to 1 table with a key. Then if a player joins it tries to find the name in the table and kick them else lets them through. Good question though.

https://developer.roblox.com/en-us/api-reference/function/DataStore/ListKeysAsync