I don't understand well the sense of this. Does it mean "they started the process of giving him the book?" Sentence looks strange. Though it can be translated as "Они начали давать ему книгу."
The verbs "идти, пойти, ходить etc" normally are applied to the pedestrian motion. Here they are not equivalent of the English "to be going to do smth."
'They were going to give him the book'='they intended to give him the book'='Они собирались дать ему книгу.' If you want to say in addition that the action was never actually undertaken, you can add corresponding phrase:
'Они собирались дать ему книгу, но так и не дали.'='They intended to give him the book but never gave.'
I don't see the way to do it without the full context. Please give the full sentence to translate, which contains all the necessary context about the idea.Can you just put it in the conditional, so that you have, 'они пойтили бы давать ему книгу'?
It is past plural third person form of the imperfective verb "собираться" , which means "to intend to", "to prepare to", "to plan to".