Map<String, dynamic> toMap() { return { if (targetUrl != null) 'targetUrl': targetUrl, if (responseCode != null) 'responseCode': responseCode, if (method != null) 'method': method, }; }