You can send multiple g-codes in one command as long as every line is separated with newline (\n) and is a new complete command. It is not possible to have a G1 move at one line and further lines only having coordinates like some g-code variants support assuming latest G commands.
How does your payload look like? Newline is %0a urlencoded, so are they included or did the newlines get stripped in bash handling?