code: def extract_common_fields(self, data):
          
          return dict(
              dc=data.get('dc'),
              role=data.get('role'),
              account_name=data.get('accountname'),
              user_id=data.get('user_id'),
              login=data.get('login'),
              login_url=data.get('login_url'),
              api_endpoint=data.get('api_endpoint'),
          )
docs: Extract fields from a metadata query.