Transmission #063: Character Inventory Persistence on Create

createCharacter now actually persists data. Previously it assembled a stub response and threw it away; now it creates a real inventory row and populates it with whatever items the caller sends in.

What changed

InventoryRepository gained two new methods following the jOOQ patterns already established in the file:

ItemModelMapper.fromDTOToModel(Item dto) is implemented (was UnsupportedOperationException). It maps the OpenAPI Item DTO to InternalItem, using a top-of-class DEFAULT_TIMESTAMP = Instant.EPOCH constant for createdAt/updatedAt when real timestamps aren’t available. Fields absent in a minimal DTO (e.g. when converting from a CharacterItem reference) fall back to empty strings or InternalItemType.MATERIAL.

CharactersApiImpl.createCharacter now:

  1. Creates a CHARACTER inventory for the new owner ID.
  2. Converts the incoming CharacterItem list to InternalItem via ItemModelMapper.fromDTOToModel, constructing a minimal Item DTO from each item reference.
  3. Calls addItems to seed the inventory.

Why it matters

Characters entering the game with a starting kit now have that kit durably stored in the database rather than silently discarded. This is the first write path through the character endpoint and sets the pattern for future character-creation logic.