You get them from killing enemies and you use them and scrip to get lock boxes that have random items in them. You can find them beside any Paradise territory shop, you can only get them one at a time and must use that one before you can get another
I keep get the message in my upper left of the screen that my key codes are maxed out. What are they and how do I use them?
They're used to purchase "booster packs" from one of the merchant terminals. I think there are 3 or 4, come with x amount of weapons of uncommon or higher quality. I think there are weapon mod boosters as well, not entirely certain though.
keycodes and keycode fragments are currency in the game to buy lockboxes from vendors that contain random items of at least uncommon (green) rarity. in the beta you can only hold 1 keycode at a time so you should spend it as soon as you get it.
At the moment there seems to be a limit of 1 Keycode. Keycodes come in fragments of eight, so you earn eight fragments by doing certain events and receive 1 Keycode then go spend it an start again. Hope that makes sense