In my opinion every marketing / SEO agency is doing a mix of both. You can optimize your content to 100%, make the site fast as you can, have a top site structure and so on..... but in the end you won't rank against your competitors when they are longer on the market and have already some natural backlinks. The times of private blogs and forums are over to gain organic backlinks. And if you don't have a great new innovation, no one will report on you and link to your site. So every SEO agency will optimize your on-page and then doing backlink building (which is already 'black hat').