-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Store headers in a read-only dictionary
- Loading branch information
Showing
1 changed file
with
4 additions
and
2 deletions.
There are no files selected for viewing
6 changes: 4 additions & 2 deletions
6
Ktisis.Common/Models/GoogleCloud/Tasks/CloudTaskHttpRequest.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,14 @@ | ||
using System.Collections.ObjectModel; | ||
|
||
namespace Ktisis.Common.Models.GoogleCloud.Tasks; | ||
|
||
public class CloudTaskHttpRequest | ||
{ | ||
public required string Url { get; init; } | ||
public readonly string HttpMethod = "POST"; | ||
public readonly Dictionary<string, string> Headers = new() | ||
public readonly ReadOnlyDictionary<string, string> Headers = new Dictionary<string, string> | ||
{ | ||
{ "Content-Type", "application/json" }, | ||
}; | ||
}.AsReadOnly(); | ||
public required string Body { get; init; } | ||
} |