Thomas considered himself more of a theologian than a philosopher, but for him, the fields of study are integrated.
"According to Thomas, only the one science that is master of all the other sciences deserves to be called wisdom (sapientia). But which science is it? If all sciences stem from an intellectual activity, then it would be the most intellectual science. As it is said in chapter II of Aristotle’s Metaphysics (982 b 1), the highest science is the one that inquires into the most intelligible objects (maxime intelligibilia). What are these maxime intelligibilia? Thomas, always the good Aristotelian, identifies three possible meanings of maxime intelligibilia, which correspond to three different regulative sciences." (Grondin, p. 96)
From the perspective of our knowledge.
"those things from which the intellect derives certitude seem to be more intelligible. Therefore, since the certitude of science is acquired by the intellect knowing causes, a knowledge of causes seems to be intellectual in the highest degree. Hence that science which considers first causes also seems to be the ruler of the others in the highest degree. (Saint Thomas Aquinas, Commentary on the Metaphysics of Aristotle, trans. John P. Rowan (Chicago: Henry Regnery Company, 1961), 1.)
Causal knowledge leads to the intelligibility of things, so a theory of causation should lead us to the most intellectual science.
We may also conceive the intelligible by comparing the intellect with the senses.
The senses are always limited to the particular, but the intellect can apprehend the universal (quod universalia comprehendit). The most intelligible science would then be the one that inquires into the most universal principles (principia maxime universalia). What are the most universal principles?
Thomas answers, following Avicenna but without naming him: Being and what accompanies it, namely, unity and plurality, potentiality and act. It is the science of Being as being that founds the universality of Thomas’s inquiry. These universal principles cannot be grasped by any particular science because they always study a specific subject (as Avicenna had already argued). Only a science of Being can account for the universal principles common and prior to all the other sciences. Thus there is a science of universal principles that is the master of all the other sciences.
The third way of conceiving the most intelligible is to separate it from matter.
The most intelligible things would therefore be the most distinct from sensible matter (as were Plato’s ideas or Aristotle’s Prime Mover). The intelligible object of this science is therefore God and intelligences separate from matter.
In summary:
He calls the science studying first causes first philosophy (prima philosophia).
He calls the science studying Being and its accompanying attributes metaphysics (metaphysica). Thomas here follows Avicenna’s lead.
Finally, he calls the science studying substances separate from matter the divine science or theology (scientia divina sive theologia), which matches Averroes’s reading of the Metaphysics.
Thomas never calls this sacred doctrine "metaphysics." There is a good reason for this. Although considering Being as a whole does lead us to the original source of Being, Thomas insists that we are unable to grasp this source because it exceeds our intellectual capacities. There is no metaphysical knowledge of God’s essence for Thomas. Therefore, he concludes, the existence of God cannot be evident in itself, it can only be demonstrated by God’s effects (much as Averroes had argued).
What Thomas is trying to express is that “any being other than God … is necessarily composed of ‘what it is’ and the act of existing (esse).” But, in God, both are merged (an idea Avicenna had already espoused): in God, and only in God, Being and essence are identical.
God does not “exist” according to Thomas, God “sub-sists.” God is only Being, pure Being, nothing but Being, pure Being subsisting by itself, the ipsum esse per se subsistens.
Although Thomas does assert (following Exodus 3: 14) that God is a pure act of being, he also acknowledges that one can only speak analogically of God’s Being. We can only speak of God from the perspective of the Being we know: a creature’s Being, which is not ipsum esse subsistens, but exists through God. God’s Being would be totally unknown to us were it not for Revelation. Therefore, one cannot really speak of metaphysics—or metaphysical knowledge of God’s Being—in the works of the doctor Angelicus.