This long story is probably not authentic. It was likely written in the late second century AD. It is one of many apocryphal "acts" that tried to add details to the New Testament book of Acts. The early church historian Eusebius said that this work and others like it were heretical, foolish, and untrue.
In this story, the apostles cast lots to determine where each should go. Matthias (Matthew in some versions) is sent to a country of people who eat human flesh. Soon, he is captured and is about to be eaten. The Lord sends Andrew to rescue him, and Andrew arrives just in time. Then a cloud lifts Matthias away to safety.
Andrew stays behind. The people arrest him, torture him, and drag him through the city. He nearly destroys the city by calling water to flow out of a statue. When the people see Andrew’s miracles, they repent (turn away from their sins) and set him free.
After that, Andrew draws a plan for a church, and the people build it. He baptizes them and teaches them to follow the ways of the Lord.
See also Andrew, the Apostle; Apocrypha.