protected ParameterXto getInDataValue(String parameterId) throws WebApplicationException {
    Interaction interaction = findInteraction();
    DataMapping dm = findDataFlow(interaction, parameterId, Direction.IN);

    ParameterXto result =
        marshalInDataValue(interaction.getModel(), dm, interaction.getInDataValue(parameterId));

    if (null == result) {
      throw new WebApplicationException(Status.NOT_FOUND);
    }

    return result;
  }
  protected String getInDataValueAsJson(String parameterId, String callback)
      throws WebApplicationException {
    Interaction interaction = findInteraction();
    DataMapping dm = findDataFlow(interaction, parameterId, Direction.IN);

    String result =
        marshalInDataValueAsJson(
            interaction.getModel(), dm, interaction.getInDataValue(parameterId));

    if (!isEmpty(callback)) {
      // provide JSONP
      result = callback + "(" + result + ");";
    }

    return result;
  }