I have started studying programming 4 years ago and started freelancing 1 year and a half ago and my current employer wants to invite me and my girlfriend to go to USA to work there temporarily (3-9 month not sure yet). What kind of visa should I apply for and what documents will I need? Does he need to send me an invitation? Do I need to prove that we are in a relation with my girlfriend?
You actually can not apply for any work visa in the US. Your employer can apply for a visa for you (probably H1B). The only visa you could apply for is a tourist visa that explicitly prohibits you from working.