The correct rewrite of the sentence "I am going to wake up by 7 am" using "was-were / going to" is: "I was going to wake up by 7 am."
In English grammar, the phrase "was going to" is used to talk about a plan or intention that was in the past but did not happen or was changed. So, when talking about a previously planned action that did not occur, we use the past tense of "am going to," which is "was going to."