Syntax fix and API mode echo mode fix