How to unlock an AT&T iPhone 4 without AT&T sim card?

I recently bought an iPhone 4 with AT&T from Ebay. I had trouble unlocking it with AT&T and decided to buy an unlock from Ebay. However, that didn't work either. A friend told me that I may have to activate a prepaid card with AT&T and unlock it from there. Both Apple and AT&T said there's nothing wrong with the phone but it's just locked on AT&T's network. If I put an AT&T sim card in the phone and try to unlock it that way, will it work?

Also, when connecting it to iTunes, it's able to be identified but it says that it can't be activates at the time and to contact customer support. When turning on the phone it doesn't activate either. I assume that's because the seller factory reset it and I don't have an AT&T sim card to activate it with.

Any suggestions or anything? ANYTHING will help. I just need to make sure the phone itself isn't broken or anything.

You aren't making any sense at all are you trying to carrier unlock it or activate the phone to use it?