XBee api arduino code not working

XBee one configured as coordinator and other configured as router. coordinator is connected to arduino and a api frame is transmitted but is not received by the router. But both XBee work absolutely fine when api frames are sent and received through XCTU. i am using software serial. Following is the code i am using please let me know if there is any mistake.

XBee_API_co_ordinator.ino (1.79 KB)