How to get token-embeddings of input with decoder-only models?

How to get token-embeddings of input with decoder-only models? Similar to last layer hidden states of the encoder-part of encoder-only or encoder-decoder models.