Although not required, it is highly recommended to hire a lawyer to file your mandamus petition. Filing a writ of mandamus is a complex process that can result in an immediate decision on your immigration case if executed properly. For more information on filing a mandamus, you can read “Mandamus Magic: Litigating Immigration Delays in Federal Court”, an article written by Managing Attorney Nicole M. Whitaker that was published in the Trial Reporter, the Journal of the Maryland Association for Justice.
A mandamus lawsuit cannot force USCIS to approve your case, but it can compel USCIS to make a decision on it, whether the decision is an approval or a denial. Before filing a mandamus, you should consult with an attorney to discuss the strength of your case and any possible reasons for the delay.