Jelajahi Sumber

redact_info_extract 加入了使用量回傳

姜青儀 8 bulan lalu
induk
melakukan
95ea6990b7
1 mengubah file dengan 22 tambahan dan 3 penghapusan
  1. 22 3
      DocAI/Data/RedactInfoExtractResponse.cs

+ 22 - 3
DocAI/Data/RedactInfoExtractResponse.cs

@@ -9,6 +9,9 @@ namespace KdanCommon.DocAI.Data
 {
     public partial class RedactInfoExtractResponse
     {
+        [JsonProperty("usage")]
+        public Usage Usage { get; set; }
+
         [JsonProperty("pages")]
         public Page[] Pages { get; set; }
 
@@ -16,6 +19,22 @@ namespace KdanCommon.DocAI.Data
         public Info[] Infos { get; set; }
     }
 
+
+    public partial class Usage
+    {
+        [JsonProperty("year")]
+        public int Year { get; set; }
+
+        [JsonProperty("month")]
+        public int Month { get; set; }
+
+        [JsonProperty("pages_used")]
+        public int PagesUsed { get; set; }
+
+        [JsonProperty("available_pages")]
+        public int AvailablePages { get; set; }
+    }
+
     public partial class Info
     {
         [JsonProperty("type")]
@@ -43,7 +62,7 @@ namespace KdanCommon.DocAI.Data
     public partial class BoundingRegion
     {
         [JsonProperty("pageNumber")]
-        public long PageNumber { get; set; }
+        public int PageNumber { get; set; }
 
         [JsonProperty("boundingPolygon")]
         public BoundingPolygon[] BoundingPolygon { get; set; }
@@ -64,10 +83,10 @@ namespace KdanCommon.DocAI.Data
     public partial class Page
     {
         [JsonProperty("pageNumber")]
-        public long PageNumber { get; set; }
+        public int PageNumber { get; set; }
 
         [JsonProperty("angle")]
-        public long Angle { get; set; }
+        public int Angle { get; set; }
 
         [JsonProperty("width")]
         public double Width { get; set; }