adding output variable in the api
refs #12