It's time for the bedroom to be vacuumed.

Amazon announced on Friday that it had reached an agreement to buy iRobot Corp., the maker of the Roomba robotic vacuum.

Dave Limp, senior vice president of Amazon Devices, said in a statement announcing the acquisition that saving time is important.

In an all-cash transaction, Amazon will acquire iRobot. Amazon bought Whole Foods for $13.7 billion and MGM for $8.5 billion last year, making them its fourth- and fifth- largest acquisitions, respectively. One Medical is a chain of primary care clinics around the United States and will be acquired by Amazon.

Amazon has a portfolio of smart home devices that include Ring doorbells and Amazon's virtual assistant and speaker.

In 2002 the Roomba hit dirty floors to the delight of lazy people and the bemusement of animals. It was described as easy, effective and fun by the New York Times.

The early version fell down stairs. According to the company, the Roomba j7 can recognize over 80 objects and return to its dock once its chores are complete. The most expensive option costs over a million dollars.

While iRobot is best known for its cleaning equipment, the technology behind it is also taking up a lot of spatial data used to map users' homes. Some digital rights groups are concerned that this data could be used to find out information about the size of homes and the contents of them.

iRobot's revenue decreased by 30 percent in the second quarter of the year. Amazon reported $121.2 billion in revenue in the second quarter, up 7.2 percent from a year earlier but down from the 7.3 percent revenue growth it reported in the first quarter of this year. Amazon grew at its lowest rate in more than two decades after the company came down from its high demands.