Accessing the pk value inside the update method in RetrieveUpdateAPIView

I want to update a specific resource in database by passing the id in the endpoint then catch it in the update method to get the specific resource. Does anyone know, how can this be access the pk inside the update method of RetrieveUpdateAPIView.