
472 A.2d 872 (1984)
AMERICAN INSURANCE COMPANY, Appellant,
v.
Robert Jonnis SMITH, Individually and t/a Bob Smith Electronic Tune-Up Center, Appellee.
No. 82-132.
District of Columbia Court of Appeals.
Argued October 20, 1982.
Decided February 13, 1984.
Steven E. Mirsky, Rockville, Md., for appellant. Robert J. Burstein, Washington, D.C., was on the brief for appellant.
*873 Gerald W. Heller, Washington, D.C., for appellee.
Before KERN, BELSON and TERRY, Associate Judges.
TERRY, Associate Judge:
Appellant sued appellee for $2,492 in unpaid premiums under an insurance contract. Appellee filed a motion to dismiss for failure to state a claim under Super.Ct.Civ.R. 12(b)(6), asserting that the money was owed by a corporation of which he was merely the agent, not by appellee himself. The trial court granted the motion; we reverse.

I
Appellant's verified complaint named appellee "individually and t/a [trading as] Bob Smith Electronic Tune-Up Center" as the sole defendant. Attached to the complaint as an exhibit was a business record which identified "Bob Smith Electronic Tune-Up Center" as the insured under the policy. Appellee filed a motion to dismiss under Rule 12(b)(6), stating that "Bob Smith Electronic Tune-Up Center, Inc." was a corporation organized under the laws of the District of Columbia and that the money allegedly owed to appellant was a debt of the corporation, not of appellee individually.[1] Appellant opposed the motion and attached to its opposition a certificate, under seal, from the office of the Recorder of Deeds, stating that "Bob Smith Electronic Tune-Up Center" was not of record as either a domestic or a foreign corporation authorized to transact business in the District of Columbia. In reply appellee admitted that he had made a mistake in his original motion and stated that "Electronic Tune-Up Center Company" was the correct name of the corporation.[2] He urged nevertheless that the motion to dismiss be granted because he could not, as a matter of law, be liable for any debt of the corporation for which he acted merely as agent.
The trial court, mistakenly believing that the motion to dismiss was unopposed, entered an order granting it. That order was set aside after appellant made a showing that it had in fact filed an opposition within the time allotted by the rules. A few weeks later, however, the trial court, having decided sua sponte that oral argument on the motion was not necessary, entered another order granting it. Appellant then filed a motion for reconsideration, accompanied by an affidavit from an official of the Department of Licenses and Inspections stating that a certificate of occupancy had been issued in the name of Robert Johnnis Smith "T/A Bob Smith Electronic Tybe-Up [sic] Center" to operate a "service station (gasoline)" at the address shown for appellee on the complaint. Appellant later submitted another affidavit from one of its own corporate officials, stating that the policy in question had been issued to "Robert J. Smith, Owner, t/a Bob Smith Electronic Tune-Up Center," and that appellant had been "without knowledge of the existence of a corporate entity" and had relied on appellee to be individually liable for the payment of premiums. The motion for reconsideration was denied, and this appeal followed.

II
The trial court was apparently led into error by appellee's incorrect characterization of his motion as a motion to dismiss under Super.Ct.Civ.R. 12(b)(6) for failure to state a claim. The motion raised an affirmative factual defense, and thus it was not properly made under Rule 12(b)(6).[3]
The Rule 12(b)(6) motion, like its common-law ancestor, the general demurrer, is intended solely to test the legal sufficiency *874 of the complaint. Like a demurrer, the motion admits all facts well pleaded but contests the plaintiff's right to any recovery based on those facts. See 5 C. WRIGHT & A. MILLER, FEDERAL PRACTICE AND PROCEDURE § 1355 (1969). Thus a Rule 12(b)(6) motion may not rely on any facts that do not appear on the face of the complaint itself. If any matters outside the complaint are presented to the court, then the rule requires that the motion be treated as one for summary judgment and disposed of as provided in Super.Ct.Civ.R. 56.
Appellee's motion raised a factual defense which had nothing to do with the legal sufficiency of appellant's complaint. The motion asserted that the debt was owed by a corporation of which appellee was only the agent, not by appellee himself. This assertion was apparently based on a misreading of the complaint. Paragraph 2 of the motion states:
Exhibit A attached to Plaintiff's Complaint demonstrates on its fact [sic] that the "account" alleged to exist is between the Plaintiff and Bob Smith Electronic Tune-Up Center, Inc.
This is simply incorrect. Exhibit A, which is a "Statement of Premium Adjustment" offered to show the amount of the debt owed, states that the insured under the policy is "Bob Smith Electronic Tune-Up Center," not "Bob Smith Electronic Tune-Up Center, Inc." The absence of "Inc." is fatal to appellee's argument, for without it there is no indication anywhere in the complaint that "Bob Smith Electronic Tune-Up Center" is a corporation. Appellee's misreading of the complaint resulted in a crucial error of fact in his motion, namely, the assertion that the debt was allegedly owed by the corporation rather than by appellee individually. Since the complaint contained no such allegation, the factual premise of appellee's motion was defective.
Moreover, it is clear from the record that the trial court accepted and considered the two affidavits offered by appellant in support of its motion for reconsideration. Putting aside any issue as to the timeliness of their filing,[4] we conclude that the trial court abused its discretion in failing to reconsider its granting of the motion to dismiss and in failing, upon such reconsideration, to deny it. As we have said, the trial court appears to have been initially led into error by the flaws in appellee's motion to dismiss. The affidavits submitted by appellant, however, focused the spotlight on the error, so that the trial court should have recognized and corrected it. The court's acceptance of the affidavits (again pretermitting any issue as to their timeliness) had two effects. First, it converted the motion to dismiss into a motion for summary judgment. Richardson v. Rivers, 118 U.S.App.D.C. 333, 335 F.2d 996 (1964); accord, e.g., Doolin v. Environmental Power, Ltd., 360 A.2d 493, 496 n. 5 (D.C.App.1976). Second, the affidavits raised a genuine issue of material fact  or rather, they reidentified the same issue of material fact that was initially raised by appellee's motion to dismiss, namely, whether appellant knew of the existence of a corporation of which appellee was the agent, or whether it believed that it was dealing with appellee as an individual. The presence of that issue in the case makes summary judgment impossible.

III
In order to avoid liability, an agent must disclose both the fact of his agency and the identity of his principal. McNeill v. Appel, 197 A.2d 152, 153 (D.C. App.1964). "Whether an agency relationship exists is a question of fact for which the person asserting it carries the burden of *875 proof." Smith v. Jenkins, 452 A.2d 333, 335 (D.C.App.1982) (citations omitted). Likewise, whether the fact of the agency and the identity of the principal were disclosed so as to protect the agent from personal liability is "a question of fact which depends upon the circumstances surrounding the particular transaction." 3 Am.Jur.2d Agency § 320 (1962) (footnote omitted); see Tarolli Lumber Co. v. Andreassi, 59 A.D.2d 1011, 399 N.Y.S.2d 739 (1977). The timing of the disclosure may also be critical. "Disclosure of the agency after execution of the contract will not relieve the agent of liability." McNeill v. Appel, supra, 197 A.2d at 153 (citation omitted); accord, Ardwin v. Englert, 81 A.D.2d 960, 439 N.Y.S.2d 720 (1981).
If appellee Smith was an agent of a corporate principal, the Electronic Tune-Up Center Company, he would nevertheless be personally liable on the insurance contract if he failed to disclose his agency and the identity of his principal before the contract was executed. McNeill v. Appel, supra; RESTATEMENT (SECOND) OF AGENCY § 322 (1958). Whether he was such an agent and whether he made timely disclosure are issues of fact in this case which must be resolved in the trial court. We therefore reverse the order of dismissal and remand the case for trial on the merits.
Reversed and remanded.
NOTES
[1]  The motion also denied that either appellee individually or "Bob Smith Electronic Tune-Up Center, Inc." owed the debt alleged in the complaint.
[2]  He also submitted a certificate, under seal, from the office of the Recorder of Deeds verifying the existence of the corporation under that name.
[3]  Super.Ct.Civ.R. 12(b) is identical to its federal counterpart, FED.R.CIV.P. 12(b).
[4]  Appellant should have filed these affidavits with its opposition to the motion to dismiss. Its failure to do so presents us with what might be, in other circumstances, a tricky question of procedure: whether a Rule 12(b)(6) motion, otherwise properly granted, may be converted into a motion for summary judgment by means of affidavits filed after the motion is decided and the case is dismissed. In this case, however, since we have found the motion to dismiss deficient on its face under Rule 12(b)(6), we need not untangle this particular procedural knot.
