I am non resident alien in USA on F-1 Visa. I worked for two companies as an independent contractor in 2017. Which form i should fill for them? W9 or W8BEN or other?

I also paid estimated tax for 2017 using form 1040 NR. Also, Paid estimated state tax for 2017.