An APA deals with the assets of a business. These can include property, contracts, equipment and resources. Purchasing a company's assets does not give you control over that company.
An SPA deals with the sale of shares in a business. Depending on the proportion sold to the buyer, this could be a controlling stake or the entire company. The buyer would also be entitled to a share of the company’s profits.
For more information, read Share purchase agreements and Asset purchase agreements.