Muhammad came to Medina as a mediator, invited to resolve the feud between the Banu Aws and the Banu Khazraj. He ultimately did so by absorbing both factions into his Muslim community and forbidding bloodshed among Muslims.