Alibaba has agreed to help Amazon.com rival ShopRunner sell to China and handle delivery within the country.