code: def oauth_unlink_external_id(external_id):
      
      with db.session.begin_nested():
          UserIdentity.query.filter_by(id=external_id['id'],
                                       method=external_id['method']).delete()
docs: Unlink a user from an external id.
  
      :param external_id: The external id associated with the user.