code: def _get_attach_id(self, key, value, attributes):
          
          if isinstance(value, dict):
              key = list(value.keys())[0]
              attributes.update(value[key])
  
              return [key, attributes]
  
          return value, attributes
docs: Get the attach record ID and extra attributes.