code: def convert_to_utc(time):
          
  
          # time is already in UTC
          if 'Z' in time:
              return time
          else:
              time_formatted = time[:-3] + time[-2:]
              dt = datetime.strptime(time_formatted, '%Y-%m-%dT%H:%M:%S%z')
              dt = dt.astimezone(timezone('UTC'))
              return dt.strftime('%Y-%m-%dT%H:%M:%SZ')
docs: Convert time to UTC
  
          Parameters
          ----------
          time    : str
              Time to convert. Has to be of the format '2016-01-01T00:00:00-08:00'.
  
          Returns
          -------
          str
              UTC timestamp.