User is read only error is showing up when try to update custom attributes for federated user

Hi All,

I am trying to update firstName, lastName, and some custom attributes of the federated users using the Admin API. but it throws error : User is read-only

Is there any way to resolve this?