I want to automate placed orders using websocket.

Hi All,
i have created strategy i am also getting the ltp from WebSocket. once i placed the buy / sell order i want to exit based on ltp price compare my strategy. what would be the process and how i can proceed further. how to implement logic for automate trading.