
796 P.2d 250 (1990)
110 N.M. 157
Richard Ralph MARTINEZ, Petitioner-Appellant,
v.
STATE of New Mexico, Respondent-Appellee.
No. 11534.
Court of Appeals of New Mexico.
March 13, 1990.
Richard Ralph Martinez, Los Lunas, pro se.
Hal Stratton, Atty. Gen., Anthony Tupler, Asst. Atty. Gen., Santa Fe, for respondent-appellee.

OPINION
HARTZ, Judge.
Petitioner appeals from the district court's order denying his petition for credit against his sentence for the time that he *251 was confined pending appeal of his conviction for first degree murder. See NMSA 1978, § 31-20-11 (Repl.Pamp. 1987). The dispositive issue in this matter is our jurisdiction. We hold that (1) petitioner had the right to appeal, because we can construe his petition as a petition for a writ of mandamus; and (2) we must transfer this appeal to the supreme court pursuant to NMSA 1978, Section 34-5-10 (Repl.Pamp. 1981), because petitioner was sentenced to life imprisonment. Before we address the law governing petitions for writs of mandamus, we discuss what petitioner's appellate rights would be if we construed his petition solely as one for a writ of habeas corpus, which is how he styled his petition in district court.

A. Habeas Corpus

Petitioner's petition stated that he was proceeding "pursuant to the purview of SCRA [1986,] Rule 5-802, Habeas Corpus, and with the exception of Chapter 44, N.M.S.A. 1978[.]" The scope of the habeas corpus rule is stated in the rule as follows:
This rule governs the procedure for filing a writ of habeas corpus by persons in custody or under restraint for a determination that such custody or restraint is, or will be, in violation of the constitution or laws of the State of New Mexico or of the United States; that the district court was without jurisdiction to impose such sentence; that the sentence was illegal or in excess of the maximum authorized by law or is otherwise subject to collateral attack.
SCRA 1986, 5-802(A). To obtain a writ of habeas corpus, a petitioner need not demonstrate a right to immediate release. See Sneed v. Cox, 74 N.M. 659, 397 P.2d 308 (1964). He need prove only that he was denied mandatory credits against his sentence and that such credits affect the timing of his release or of a parole hearing. See id. Because credits for the period of time that petitioner was confined pending appeal of his conviction are counted in calculating time served, petitioner's claim is within the scope of Rule 5-802.
The court of appeals, however, does not have jurisdiction to review a district court's denial of a Rule 5-802 petition. Paragraph G of the rule specifies that if the writ is denied, a petition for certiorari may be filed with the supreme court within thirty days of the district court's decision. See SCRA 1986, 12-501 (rule governing petitions for writs of certiorari seeking review of district court denials of habeas corpus petitions).

B. Mandamus

Despite petitioner's failure to label his petition specifically as one seeking a writ of mandamus, see NMSA 1978, §§ 44-2-1 to -14 (statute governing mandamus), we can so construe his petition. If a pleading, by its allegations and the relief requested, discloses an action in mandamus, it will be so treated. Cf. SCRA 1986, 1-008(F) ("All pleadings shall be so construed as to do substantial justice."); Phelps Dodge Corp. v. Guerra, 92 N.M. 47, 582 P.2d 819 (1978) (nomenclature of pleading not significant).
The purpose of a writ of mandamus is to compel a tribunal, corporation, board, or person to perform an act specifically enjoined by law. § 44-2-4. Petitioner alleges that, contrary to the mandatory terms of Section 31-20-11, he did not receive credit against his life sentence for 244 days of official confinement while he was awaiting the outcome of his appeal from a conviction for first degree murder. Thus, the essence of petitioner's petition is a request for a writ of mandamus. See Conston v. New Mexico State Bd. of Probation & Parole, 79 N.M. 385, 444 P.2d 296 (1968) (mandamus to board to give credit for time served).
The petition is technically deficient because it does not identify the responsible state actor. Although the Corrections Department bears responsibility for compliance with mandatory post-sentencing credit requirements, see NMSA 1978, §§ 33-1-4(A), -2-38 (Repl.Pamp. 1987), petitioner named the state of New Mexico as the respondent, and his prayer for relief indicates that the district court should itself *252 grant the credit. Nevertheless, the district court may consider the petition as if it had named the proper party. Pro se petitions are regarded with a tolerant eye. Courts will consider a petition if "the essential elements prerequisite to the granting of the relief sought can be found or reasonably inferred." Birdo v. Rodriguez, 84 N.M. 207, 209, 501 P.2d 195, 197 (1972). From the information in petitioner's petition, the district court could have inferred the proper respondent. The district court could then direct the writ to that party. This would afford the proper respondent adequate notice, because the respondent answers the writ, see §§ 44-2-9, -11, not the petition itself.
Final judgments in mandamus matters may be reviewed by appeal. See § 44-2-14. This court, however, does not have appellate jurisdiction over post-conviction remedy proceedings where the sentence involved is death or life imprisonment. See SCRA 1986, 12-102(A)(2); NMSA 1978, § 34-5-8(A)(4) (Cum.Supp. 1989). The present case is a post-conviction remedy proceeding. See State v. Castillo, 94 N.M. 352, 610 P.2d 756 (Ct.App. 1980) (construing "post conviction remedy proceedings"). In accordance with Section 34-5-10, we therefore transfer this appeal to the supreme court.

C. Conclusion

For the reasons stated, we transfer this appeal to the New Mexico Supreme Court.
IT IS SO ORDERED.
ALARID and APODACA, JJ., concur.
