code: public Map<String, Object> build() {
          final ImmutableMap.Builder<String, Object> builder = ImmutableMap.builder();
          final int keyCode = ofNullable(this.keyCode)
                  .orElseThrow(() -> new IllegalStateException("The key code must be set"));
          builder.put("keycode", keyCode);
          ofNullable(this.metaState).ifPresent(x -> builder.put("metastate", x));
          ofNullable(this.flags).ifPresent(x -> builder.put("flags", x));
          return builder.build();
      }
docs: Builds a map, which is ready to be used by the downstream API.
  
  @return API parameters mapping
  @throws IllegalStateException if key code is not set