31 lines
840 B
C#
31 lines
840 B
C#
|
using System.Text.Json.Serialization;
|
||
|
|
||
|
namespace FortranWebApi.Models
|
||
|
{
|
||
|
public class ApiResponse<T>
|
||
|
{
|
||
|
[JsonPropertyName("message")]
|
||
|
public string Message { get; set; } = "Success";
|
||
|
|
||
|
[JsonPropertyName("success")]
|
||
|
public bool Success { get; set; } = true;
|
||
|
|
||
|
[JsonPropertyName("data")]
|
||
|
public ApiResponseData<T>? Data { get; set; }
|
||
|
}
|
||
|
|
||
|
public class ApiResponseData<T>
|
||
|
{
|
||
|
[JsonPropertyName("contentType")]
|
||
|
public string? ContentType { get; set; }
|
||
|
|
||
|
[JsonPropertyName("serializerSettings")]
|
||
|
public object? SerializerSettings { get; set; }
|
||
|
|
||
|
[JsonPropertyName("statusCode")]
|
||
|
public int? StatusCode { get; set; }
|
||
|
|
||
|
[JsonPropertyName("value")]
|
||
|
public T? Value { get; set; }
|
||
|
}
|
||
|
}
|