create callflow function