Can Channel Divinity: Preserve Life target swallowed creatures?

I saw this question and was reminded of something that happened in one of my games recently: I, as a Life Cleric, used my Channel Divinity: Preserve Life feature on an ally who had been swallowed (It didn’t affect the outcome significantly; I had two other possible plans that would probably have saved said ally).

But I’m curious. My ally had total cover, which prevented targetting her with a spell (say, Mass Cure Wounds, as in the linked question). But Preserve Life is not a spell. RAW, is this legal?