Trump tweeted that he had spoken with Prime Minister Stefan Lofven, who he said gave assurances that the singer would be treated fairly.
“Likewise, I assured him that A$AP was not a flight risk and offered to personally vouch for his bail, or an alternative,” Trump wrote.
Just had a very good call with @SwedishPM Stefan Löfven who assured me that American citizen A$AP Rocky will be treated fairly. Likewise, I assured him that A$AP was not a flight risk and offered to personally vouch for his bail, or an alternative….
— Donald J. Trump (@realDonaldTrump) July 20, 2019
There is no system of bail in Sweden.
Trump said he and Lofven had agreed to speak again over the next 48 hours.
Lofven's spokesman Toni Eriksson described the 20-minute phone call as “friendly and respectful”.
The prime minister “made certain to emphasize the complete independence of the Swedish judicial system, prosecutors and courts,” Eriksson said in an emailed statement.
“He underlined that in Sweden everyone is equal before the law and that the government cannot and will not attempt to influence the legal proceedings.”
Follow-up conversations may take place, “but nothing has been booked or planned,” he added.
Fans, fellow artists and US Congress members have campaigned for the 30-year-old artist, whose real name is Rakim Mayers, to be freed since his arrest on July 3 following the fight on June 30.
Prosecutors had faced a deadline on Friday to press charges or release the artist. They requested an extension to finish the probe, and the Stockholm District Court granted it, setting a new deadline of July 25.
Trump intervened after an appeal to him from rapper Kanye West and his wife Kim Kardashian.
Mayer has claimed he was acting in self defense after two young men harassed and followed him and his entourage.
Three other people were arrested alongside Mayer and one of them — the rapper's bodyguard — was later released.
Part of the incident was captured on amateur video published by entertainment outlet TMZ.
In the video, the rapper, who was in Stockholm for a concert, can be seen throwing one of the men into the street and then aiming several punches at him while he is down.
But Mayers posted his own videos on Instagram showing the lead-up to the clash, in which the young man can be seen arguing with the rapper, who repeatedly asks the man and his friend to stop following them.
One of the young men can also been seen hitting a member of the artist's entourage.