Ananias and Sapphira were indeed struck down by God. In a community with total openness and transparency, they dared to introduce deceit.
It is written that the community of believers then were of one heart and one mind (Acts 4:32-33, The Message). They shared everything as none of them claimed ownership of their possessions. None of them lacked because those who owned lands and houses sold them and brought the cost of sale to the apostles as offerings. Each time such money is brought, it is distributed according to everyone's need. An example was given of Joseph also called Barnabas who sold his field and brought the money.
I perceive that Ananias and his wife, Sapphira did not set out to make sacrifice like Joseph did but they wanted recognition and perhaps praises from the community. It was more of a show than giving. So they both agreed to sell their land but were not ready to give up all the money. Now the mandate is not that they should give up all the money but they wanted it to appear so since some other believers gave all. They did not want to part with all but at the same time wanted to belong to the category of those that gave all. So they kept part of the money and brought the remaining to the apostles (Acts 5:1-11) giving the impression it was all.
All Peter did was to ask him questions and made one statement: Peter said, "Ananias, how did Satan get you to lie to the Holy Spirit and secretly keep back part of the price of the field? Before you sold it, it was all yours, and after you sold it, the money was yours to do with as you wished. So what got into you to pull a trick like this? You didn't lie to men but to God" (Acts 5:3-4, The Message). Ananias fell down dead after those words. There was no physical attempt to kill Ananias - Peter did not proclaim his death; he was not given poison to drink; he was not struck down by the sword. The apostles watched as Ananias fell down dead after Peter's words. It was stated that the fear of God was upon everyone who heard of Ananias' death.
Sapphira came in not knowing what has befallen her husband maintained the story line she had agreed with her husband which was to say the money they brought was the price of the land. Peter told her that she and her husband conspired against the spirit of God and those who buried her husband were at the door and she was next. Sapphira fell down dead. Once again, there was not physical or magical attempt to kill her.
Ananias and his wife did not know they were not lying to men but to God and so God struck them dead. The church knew then that God was not one to be messed with and so there was a great respect for God.