
691 P.2d 765 (1984)
Jackson B. WELLS, Plaintiff-Appellant,
v.
PREMIER INDUSTRIAL CORPORATION, Phillip Sims, and R.J. McGorray, Defendants-Appellees.
No. 83CA0253.
Colorado Court of Appeals, Div. III.
November 15, 1984.
*766 Jackson B. Wells, pro se, appellant.
Davis, Graham & Stubbs, Robert L. Morris, Timothy M. Tymkovich, Denver, for defendants-appellees.
METZGER, Judge.
Plaintiff, Jackson B. Wells, appeals from a summary judgment dismissing his complaint *767 on grounds of res judicata, and from an order awarding attorney fees for groundless and frivolous litigation. We affirm in part and reverse in part.
Wells sued defendants, his former employers, Premier Industrial Corporation, Phillip Sims, and R.J. McGorray, in the United States District Court for the District of Colorado. He sought damages alleging that defendants had violated his rights under the Fourth and Fifth Amendments by complying with a summons issued by the Internal Revenue Service (I.R. S.). The I.R.S. summons required defendants to provide forms and ledgers showing all compensation paid to Wells, deductions claimed by him, and expenses charged to him.
In June 1982, the action was dismissed for failure to state a claim upon which relief could be granted. The court held that because the defendants were not state or federal agents, there was no right to constitutional relief. Further, the court concluded that defendants did not violate the "summons provisions" of the Internal Revenue Code, and therefore, there was no question of a private remedy pursuant to Cort v. Ash, 422 U.S. 66, 95 S.Ct. 2080, 45 L.Ed.2d 26 (1975). Wells did not appeal.
In August 1982, Wells filed a complaint in Arapahoe County District Court naming the same defendants and alleging the same facts. He again sought relief under the Fourth and Fifth Amendments, but also included claims under Colo.Const. art. II, § 3, and Colo.Const. art. II, § 7. The thrust of these claims was that defendants had violated Wells' "privacy" interests by complying with the I.R.S. summons.
The trial court granted defendants' motion for summary judgment. It held that the federal court had taken jurisdiction of the issues raised in Wells' first complaint and that its dismissal for failure to state a claim constituted a "final judgment." Therefore, the court concluded it was without authority to adjudicate the issues raised by Wells' state court complaint.

I.
Wells first contends that the trial court erred in applying the doctrine of res judicata to his Fourth and Fifth Amendment claims. Specifically, he argues that the federal decision was a dismissal for lack of jurisdiction and, thus, not an adjudication on the merits.
Invocation of the doctrine of res judicata requires that the former judgment to have been entered "on the merits" and to have concerned a matter within the jurisdiction of the rendering court. Pomponio v. Larsen, 80 Colo. 318, 251 P. 534 (1926). Dismissal for failure to state a claim is an adjudication on the merits pursuant to Fed. R.Civ.P. 41(b), which provides that:
"Unless the court in its order for dismissal otherwise specifies, a dismissal under this subdivision and any dismissal not provided for in this rule, other than a dismissal for lack of jurisdiction ... operates as an adjudication upon the merits."
Wells seeks to invoke the jurisdiction exception. He argues that because the federal court found no ground for relief, its order amounted to a dismissal for lack of subject matter jurisdiction. However, the court expressed no reservation concerning its power to decide the case as one arising under the Constitution and laws of the United States. See 28 U.S.C. § 1331(a). The fact that the court found no cause of action has no bearing on the issue of its jurisdiction to make that determination. Consequently, res judicata barred relitigation of Wells' Fourth and Fifth Amendment claims.

II.
Wells next contends that his state claim, premised on a right to privacy grounded in the Colorado Constitution, is not barred by res judicata. Citing United Mine Workers v. Gibbs, 383 U.S. 715, 86 S.Ct. 1130, 16 L.Ed.2d 218 (1966), he argues that there were no "substantial" federal issues presented in the first case, and therefore, the federal court would have declined to *768 exercise pendent jurisdiction over the state claim.
Even if we assume that Wells is correct, we conclude that the judgment must be affirmed on separate grounds. Specifically, we hold that the complaint fails to state a claim upon which relief can be granted and thus was properly dismissed pursuant to C.R.C.P. 12(b)(5). While the trial court did not rule on this basis, we are not precluded from doing so, since the question is purely one of law. Chroma Corp. v. Campbell, 44 Colo.App. 387, 619 P.2d 74 (1980).
Dismissals for failure to state a claim are viewed unfavorably, and should be granted only when the plaintiff "can prove no set of facts in support of his claim which would entitle him to relief." Davidson v. Dill, 180 Colo. 123, 503 P.2d 157 (1972). This is particularly true where constitutional rights are allegedly at issue. Davidson v. Dill, supra. But, even applying this stringent standard, we perceive no factual allegations which could support a recovery for violation of Wells' right to privacy.
In Rugg v. McCarty, 173 Colo. 170, 476 P.2d 753 (1970), our Supreme Court first recognized an actionable tort founded on invasion of privacy. Without defining either the source or scope of the right, the court held that "unreasonable action" by creditors, which "foreseeably will probably result in extreme mental anguish" to a person of ordinary sensibilities, constitutes a violation of the right to privacy.
In Lincoln v. Denver Post, 31 Colo.App. 283, 501 P.2d 152 (1972), we further delineated the scope of the right to privacy. In that case, the Denver Post published information concerning Lincoln's application for aid to dependent children, despite a statutory prohibition. We held that because Lincoln had been charged with welfare fraud, the public's right to be informed concerning the administration of justice outweighed Lincoln's right to privacy.
Here, the substance of the complaint is that the Internal Revenue Service served the defendants with a summons. The defendants notified Wells of the summons and stated their intention to comply unless a court relieved them of this responsibility. Wells wrote to defendants objecting on the basis of his constitutional rights to their proposed compliance, but took no other action. Defendants then complied with the summons.
Based on the foregoing, we perceive no basis for Wells to recover damages based on invasion of privacy. The actions of defendants were eminently reasonable, since non-compliance with the summons could have subjected them to punishment for contempt. 26 U.S.C. § 7604(b). Furthermore, defendants notified Wells of the summons, thus affording him an opportunity to seek relief.
Moreover, the public has an interest in enforcing the tax laws through use of the administrative summons. Here, the federal court has already determined that defendants did not violate any federal law by complying with the summons. Consequently, Wells' right to privacy, if any, is outweighed by the legitimate investigation of tax liability. The purpose of the right to privacy is not to hinder tax investigations by subjecting a subpoenaed witness to civil liability. See Lincoln v. Denver Post, supra.

III.
Wells also contends that the trial court's award of attorney fees to defendants should be set aside. We agree.
The trial court ruled that the action was groundless and frivolous because res judicata barred consideration of the issues raised in Wells' complaint. However, Wells' argument that the federal court lacked pendent jurisdiction over his state claim is not without merit. See United Mine Workers v. Gibbs, supra. Consequently, the award of attorney fees must be set aside.
The defendants' request for attorney fees on appeal is denied.
*769 The judgment of the trial court is affirmed insofar as it dismissed the complaint. The award of attorney fees is reversed.
KELLY and TURSI, JJ., concur.
