Cleaned up print outs, added commands and improved the code generated for the api recording