What happens in the end of the Tokyo Ravens anime? Harutora's attempt to resurrect Natsume supposedly succeeded, but Saotome Suzu, who had helped to perform the ritual, told the other characters over the phone that it technically was a success.

In the end, we see how Natsume is resting in a bed inside a brightly sunlit room with a window open. Harutora says he'll be looking forward to see her and disappears. It's not clear whether he was real or not, and whether the whole room is some metaphor of sorts, considering the "astrology" stuff in the previous episode.

What's really going on in the end of the anime?
This is still unclear in the anime. As of the time of writing, there are 11 volumes of light novel and the anime adaptation has covered up to volume 9 (titled to The DarkSky).
From volume 9 chapter 5 (emphasis mine):

Was it a dream? She wasn't sure. Her fuzzy brain still wasn't working well. The sheets completely covered Natsume, and everything was unclear, so she couldn't make a normal judgment.
Natsume softly touched her lips with her fingers. The sensation lingering there was inexplicably fresh, clear, and real. Natsume's face reddened and she buried her face in the covers again.

He is real. The incident did happen but we are not sure where. Resurrection was successful but there may other thing needed to be done for Natsume to live in real world.
The technical success Suzu was talking about is explained more clearly in volume 10 chapter 3:

 &quot;Yes. I won't hide it any longer. My name is Tsuchimikado Natsume. I was adopted by the Tsuchimikado main family not long after birth and was raised as the next family head. Tsuchimikado Harutora is my childhood friend.&quot;

  

 &quot;Also...... It's true that I'm a dead person. Last summer, I was resurrected from death. ......No, I was just awakened, and right now I'm still barely maintaining my current state.&quot;

In the future, there may be an OVA for the remaining part of LN which may go into detail on it.