factor out get and send text