code: def to_geojson(products):
          
          feature_list = []
          for i, (product_id, props) in enumerate(products.items()):
              props = props.copy()
              props['id'] = product_id
              poly = geomet.wkt.loads(props['footprint'])
              del props['footprint']
              del props['gmlfootprint']
              # Fix "'datetime' is not JSON serializable"
              for k, v in props.items():
                  if isinstance(v, (date, datetime)):
                      props[k] = v.strftime('%Y-%m-%dT%H:%M:%S.%fZ')
              feature_list.append(
                  geojson.Feature(geometry=poly, id=i, properties=props)
              )
          return geojson.FeatureCollection(feature_list)
docs: Return the products from a query response as a GeoJSON with the values in their
          appropriate Python types.