@JsonSerializer.Serialize(Model)
13 |Use this page to detail your site's privacy policy.
11 | -------------------------------------------------------------------------------- /WhatsappBusiness.CloudApi/MessageHistory/Requests/MessageHistoryRequest.cs: -------------------------------------------------------------------------------- 1 | using System.Text.Json.Serialization; 2 | 3 | namespace WhatsappBusiness.CloudApi.MessageHistory.Requests 4 | { 5 | public class MessageHistoryRequest 6 | { 7 | [JsonPropertyName("messaging_product")] 8 | [JsonInclude] 9 | public string MessagingProduct { get; private set; } = "whatsapp"; 10 | 11 | [JsonPropertyName("sync_type")] 12 | public string SyncType { get; set; } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /WhatsappBusiness.CloudApi/Response/TemplateMessageCreationResponse.cs: -------------------------------------------------------------------------------- 1 | using System.Text.Json.Serialization; 2 | 3 | namespace WhatsappBusiness.CloudApi.Response 4 | { 5 | public class TemplateMessageCreationResponse 6 | { 7 | [JsonPropertyName("id")] 8 | public string Id { get; set; } 9 | 10 | [JsonPropertyName("status")] 11 | public string Status { get; set; } 12 | 13 | [JsonPropertyName("category")] 14 | public string Category { get; set; } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /WhatsappBusiness.CloudApi/Response/BaseSuccessResponse.cs: -------------------------------------------------------------------------------- 1 | using System.Text.Json.Serialization; 2 | 3 | namespace WhatsappBusiness.CloudApi.Response 4 | { 5 | public class BaseSuccessResponse 6 | { 7 | [JsonPropertyName("messaging_product")] 8 | [JsonIgnore(Condition = JsonIgnoreCondition.WhenWritingNull)] 9 | public string MessagingProduct { get; set; } 10 | 11 | [JsonPropertyName("success")] 12 | public bool Success { get; set; } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /WhatsappBusiness.CloudApi/Registration/Requests/RegisterPhoneRequest.cs: -------------------------------------------------------------------------------- 1 | using System.Text.Json.Serialization; 2 | 3 | namespace WhatsappBusiness.CloudApi.Registration.Requests 4 | { 5 | public class RegisterPhoneRequest 6 | { 7 | [JsonPropertyName("messaging_product")] 8 | [JsonInclude] 9 | public string MessagingProduct { get; private set; } = "whatsapp"; 10 | 11 | [JsonPropertyName("pin")] 12 | public string Pin { get; set; } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /WhatsappBusiness.CloudApi/Response/ResumableUploadResponse.cs: -------------------------------------------------------------------------------- 1 | using System.Text.Json.Serialization; 2 | 3 | namespace WhatsappBusiness.CloudApi.Response 4 | { 5 | public class ResumableUploadResponse 6 | { 7 | [JsonPropertyName("id")] 8 | public string Id { get; set; } 9 | 10 | [JsonPropertyName("file_offset")] 11 | public long FileOffset { get; set; } 12 | 13 | [JsonPropertyName("h")] 14 | public string H { get; set; } 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /WhatsappBusiness.CloudApi/Webhook/BusinessInitiatedMessageSentStatus.cs: -------------------------------------------------------------------------------- 1 | using System.Collections.Generic; 2 | using System.Text.Json.Serialization; 3 | 4 | namespace WhatsappBusiness.CloudApi.Webhook 5 | { 6 | ///@JsonSerializer.Serialize(Model)
13 |@JsonSerializer.Serialize(Model)
13 |