implemented and tested functionality to create sa_payload from