Handled serialization for custom url handler.