Throttle nit working

I had to buy a throttle and how do i know if compatible with my ebike XF900?