Hi @slecraphi
Just to elaborate on @ehalit’s correct approach here your example adapted for token classification:
tokenizer = BertTokenizer.from_pretrained('bert-base-uncased')
model = BertForTokenClassification.from_pretrained('bert-base-uncased')
inputs = tokenizer("Hello, my dog is cute", return_tensors='pt')
outputs = model(**inputs, output_hidden_states=True)
last_hidden_states = outputs.hidden_states[-1]

The shape of last_hidden_states will be [batch_size, tokens, hidden_dim] so if you want to get the embedding of the first element in the batch and the [CLS] token you can get it with last_hidden_states[0,0,:].
Hope this helps!