mirror of
https://gitee.com/fudiwei/DotNetCore.SKIT.FlurlHttpClient.Wechat.git
synced 2025-07-15 23:13:32 +08:00
feat(tenpayv2): 新增单品优惠退款相关接口
This commit is contained in:
parent
a903743a77
commit
df1f75732f
@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
using System.Net.Http;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
@ -228,6 +228,44 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2
|
||||
return await client.SendRequestWithXmlAsync<Models.GetPayRefundResponse>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /secapi/pay/refundv2 接口。</para>
|
||||
/// <para>REF: https://pay.weixin.qq.com/wiki/doc/api/danpin.php?chapter=9_103 </para>
|
||||
/// </summary>
|
||||
/// <param name="client"></param>
|
||||
/// <param name="request"></param>
|
||||
/// <param name="cancellationToken"></param>
|
||||
/// <returns></returns>
|
||||
public static async Task<Models.CreatePayRefundV2Response> ExecuteCreatePayRefundV2Async(this WechatTenpayClient client, Models.CreatePayRefundV2Request request, CancellationToken cancellationToken = default)
|
||||
{
|
||||
if (client is null) throw new ArgumentNullException(nameof(client));
|
||||
if (request is null) throw new ArgumentNullException(nameof(request));
|
||||
|
||||
IFlurlRequest flurlReq = client
|
||||
.CreateRequest(request, HttpMethod.Post, "secapi", "pay", "refundv2");
|
||||
|
||||
return await client.SendRequestWithXmlAsync<Models.CreatePayRefundV2Response>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /pay/refundqueryv2 接口。</para>
|
||||
/// <para>REF: https://pay.weixin.qq.com/wiki/doc/api/danpin.php?chapter=9_104 </para>
|
||||
/// </summary>
|
||||
/// <param name="client"></param>
|
||||
/// <param name="request"></param>
|
||||
/// <param name="cancellationToken"></param>
|
||||
/// <returns></returns>
|
||||
public static async Task<Models.GetPayRefundV2Response> ExecuteGetPayRefundV2Async(this WechatTenpayClient client, Models.GetPayRefundV2Request request, CancellationToken cancellationToken = default)
|
||||
{
|
||||
if (client is null) throw new ArgumentNullException(nameof(client));
|
||||
if (request is null) throw new ArgumentNullException(nameof(request));
|
||||
|
||||
IFlurlRequest flurlReq = client
|
||||
.CreateRequest(request, HttpMethod.Post, "pay", "refundqueryv2");
|
||||
|
||||
return await client.SendRequestWithXmlAsync<Models.GetPayRefundV2Response>(flurlReq, data: request, cancellationToken: cancellationToken);
|
||||
}
|
||||
|
||||
#region Bill
|
||||
/// <summary>
|
||||
/// <para>异步调用 [POST] /pay/downloadbill 接口。</para>
|
||||
|
@ -1,4 +1,4 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /deposit/consume 接口的请求。</para>
|
||||
@ -52,7 +52,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int TotalFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@ -67,7 +66,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("consume_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("consume_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int ConsumeFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
@ -93,7 +93,6 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int TotalFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
@ -93,7 +93,6 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int TotalFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /deposit/refund 接口的请求。</para>
|
||||
@ -59,7 +59,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int TotalFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@ -67,7 +66,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refund_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refund_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int RefundFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
@ -84,7 +84,6 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int TotalFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /cgi-bin/mch/customs/customdeclareorder 接口的请求。</para>
|
||||
@ -59,7 +59,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("duty")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("duty")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int? Duty { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@ -81,7 +80,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("order_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("order_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int? OrderFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@ -89,7 +87,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("transport_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("transport_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int? TransportFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@ -97,7 +94,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("product_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("product_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int? ProductFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /pay/pappayapply 接口的请求。</para>
|
||||
@ -63,7 +63,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int TotalFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
@ -54,7 +54,6 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int TotalFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@ -157,7 +156,6 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("plan_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("plan_id")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int PlanId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@ -172,7 +170,6 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("request_serial")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("request_serial")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public long RequestSerialNumber { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [GET] /papay/h5entrustweb 接口的请求。</para>
|
||||
@ -32,7 +32,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("plan_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("plan_id")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int PlanId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@ -47,7 +46,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("request_serial")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("request_serial")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public long RequestSerialNumber { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /papay/preentrustweb 接口的请求。</para>
|
||||
@ -32,7 +32,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("plan_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("plan_id")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int PlanId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@ -47,7 +46,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("request_serial")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("request_serial")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public long RequestSerialNumber { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
@ -91,7 +91,6 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int TotalFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -9,129 +9,25 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
public static class Types
|
||||
{
|
||||
public class PromotionDetail
|
||||
public class PromotionDetail : GetPayOrderResponse.Types.PromotionDetail
|
||||
{
|
||||
public static class Types
|
||||
public static new class Types
|
||||
{
|
||||
public class Promotion
|
||||
public class Promotion : GetPayOrderResponse.Types.PromotionDetail.Types.Promotion
|
||||
{
|
||||
public static class Types
|
||||
public static new class Types
|
||||
{
|
||||
public class GoodsDetail
|
||||
public class GoodsDetail : GetPayOrderResponse.Types.PromotionDetail.Types.Promotion.Types.GoodsDetail
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置商品编码。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("goods_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("goods_id")]
|
||||
public string GoodsId { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商品数量。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("quantity")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("quantity")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int Quantity { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商品单价(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("price")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("price")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int Price { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商品优惠金额(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("discount_amount")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("discount_amount")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int DiscountAmount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商品备注。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("goods_remark")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("goods_remark")]
|
||||
public string? GoodsRemark { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置券或者立减优惠 ID。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("promotion_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("promotion_id")]
|
||||
public string PromotionId { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置优惠名称。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("name")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("name")]
|
||||
public string? Name { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置优惠范围。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("scope")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("scope")]
|
||||
public string? Scope { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置优惠类型。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("type")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("type")]
|
||||
public string? Type { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置优惠券面额(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("amount")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("amount")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int Amount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置活动 ID。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("activity_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("activity_id")]
|
||||
public string? ActivityId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置微信出资(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("wxpay_contribute")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("wxpay_contribute")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int? WechatpayContribute { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商户出资(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("merchant_contribute")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("merchant_contribute")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int? MerchantContribute { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置其他出资(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("other_contribute")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("other_contribute")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int? OtherContribute { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置单品列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("goods_detail")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("goods_detail")]
|
||||
public Types.GoodsDetail[]? GoodsList { get; set; }
|
||||
public new Types.GoodsDetail[]? GoodsList { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
@ -140,7 +36,7 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("promotion_detail")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("promotion_detail")]
|
||||
public Types.Promotion[]? PromotionList { get; set; }
|
||||
public new Types.Promotion[]? PromotionList { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /secapi/pay/refund 接口的请求。</para>
|
||||
@ -59,7 +59,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int TotalFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@ -67,9 +66,15 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refund_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refund_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int RefundFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置现金退款金额(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("cash_refund_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("cash_refund_fee")]
|
||||
public int? CashRefundFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置货币类型。
|
||||
/// </summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /secapi/pay/refund 接口的响应。</para>
|
||||
|
@ -0,0 +1,189 @@
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /secapi/pay/refundv2 接口的请求。</para>
|
||||
/// </summary>
|
||||
public class CreatePayRefundV2Request : WechatTenpaySignableRequest
|
||||
{
|
||||
public static class Types
|
||||
{
|
||||
public class Detail
|
||||
{
|
||||
public static class Types
|
||||
{
|
||||
public class GoodsDetail
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置商户侧商品编码。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("goods_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("goods_id")]
|
||||
public string MerchantGoodsId { get; set; } = string.Empty;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置微信侧商品编码。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("wxpay_goods_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("wxpay_goods_id")]
|
||||
public string? WechatpayGoodsId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商品名称。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("goods_name")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("goods_name")]
|
||||
public string? GoodsName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商品单价(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("price")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("price")]
|
||||
public int Price { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商品退款金额(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refund_amount")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refund_amount")]
|
||||
public int RefundAmount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商品退货数量。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refund_quantity")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refund_quantity")]
|
||||
public int RefundQuantity { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置单品列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("goods_detail")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("goods_detail")]
|
||||
public List<Types.GoodsDetail>? GoodsList { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
internal static class Converters
|
||||
{
|
||||
internal class RequestPropertyDetailNewtonsoftJsonConverter : Newtonsoft.Json.Converters.TextualObjectInJsonFormatConverterBase<Types.Detail>
|
||||
{
|
||||
}
|
||||
|
||||
internal class RequestPropertyDetailSystemTextJsonConverter : System.Text.Json.Converters.TextualObjectInJsonFormatConverterBase<Types.Detail>
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// <inheritdoc/>
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("mch_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("mch_id")]
|
||||
public override string? MerchantId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// <inheritdoc/>
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("appid")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("appid")]
|
||||
public override string? AppId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置子商户号。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("sub_mch_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("sub_mch_id")]
|
||||
public string? SubMerchantId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置子商户 AppId。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("sub_appid")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("sub_appid")]
|
||||
public string? SubAppId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商户订单号。与字段 <see cref="TransactionId"/> 二选一。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("out_trade_no")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("out_trade_no")]
|
||||
public string? OutTradeNumber { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置微信支付订单号。与字段 <see cref="OutTradeNumber"/> 二选一。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("transaction_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("transaction_id")]
|
||||
public string? TransactionId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商户退款单号。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("out_refund_no")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("out_refund_no")]
|
||||
public string OutRefundNumber { get; set; } = string.Empty;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置订单金额(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_fee")]
|
||||
public int TotalFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置退款金额(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refund_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refund_fee")]
|
||||
public int RefundFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置现金退款金额(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("cash_refund_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("cash_refund_fee")]
|
||||
public int? CashRefundFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置货币类型。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refund_fee_type")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refund_fee_type")]
|
||||
public string? RefundFeeType { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置退款原因。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refund_desc")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refund_desc")]
|
||||
public string? Description { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置通知地址。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("notify_url")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("notify_url")]
|
||||
public string? NotifyUrl { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置退款资金来源。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refund_account")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refund_account")]
|
||||
public string? RefundAccount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商品信息。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("detail")]
|
||||
[Newtonsoft.Json.JsonConverter(typeof(Converters.RequestPropertyDetailNewtonsoftJsonConverter))]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("detail")]
|
||||
[System.Text.Json.Serialization.JsonConverter(typeof(Converters.RequestPropertyDetailSystemTextJsonConverter))]
|
||||
public Types.Detail? Detail { get; set; }
|
||||
}
|
||||
}
|
@ -0,0 +1,156 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /secapi/pay/refundv2 接口的响应。</para>
|
||||
/// </summary>
|
||||
public class CreatePayRefundV2Response : WechatTenpaySignableResponse
|
||||
{
|
||||
public static class Types
|
||||
{
|
||||
public class PromotionDetail : GetPayRefundV2Response.Types.PromotionDetail
|
||||
{
|
||||
public static new class Types
|
||||
{
|
||||
public class Promotion : GetPayRefundV2Response.Types.PromotionDetail.Types.Promotion
|
||||
{
|
||||
public static new class Types
|
||||
{
|
||||
public class GoodsDetail : GetPayRefundV2Response.Types.PromotionDetail.Types.Promotion.Types.GoodsDetail
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置单品列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("goods_detail")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("goods_detail")]
|
||||
public new Types.GoodsDetail[]? GoodsList { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置优惠信息列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("promotion_detail")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("promotion_detail")]
|
||||
public new Types.Promotion[]? PromotionList { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
internal static class Converters
|
||||
{
|
||||
internal class ResponsePropertyPromotionDetailNewtonsoftJsonConverter : Newtonsoft.Json.Converters.TextualObjectInJsonFormatConverterBase<Types.PromotionDetail>
|
||||
{
|
||||
}
|
||||
|
||||
internal class ResponsePropertyPromotionDetailSystemTextJsonConverter : System.Text.Json.Converters.TextualObjectInJsonFormatConverterBase<Types.PromotionDetail>
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// <inheritdoc/>
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("mch_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("mch_id")]
|
||||
public override string? MerchantId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// <inheritdoc/>
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("appid")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("appid")]
|
||||
public override string? AppId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置子商户号。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("sub_mch_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("sub_mch_id")]
|
||||
public string? SubMerchantId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置子商户 AppId。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("sub_appid")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("sub_appid")]
|
||||
public string? SubAppId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商户订单号。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("out_trade_no")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("out_trade_no")]
|
||||
public string OutTradeNumber { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置微信支付订单号。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("transaction_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("transaction_id")]
|
||||
public string TransactionId { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商户退款单号。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("out_refund_no")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("out_refund_no")]
|
||||
public string OutRefundNumber { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置微信退款单号。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refund_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refund_id")]
|
||||
public string RefundId { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置订单金额(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int TotalFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置货币类型。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("fee_type")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("fee_type")]
|
||||
public string? FeeType { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置退款金额(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refund_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refund_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int RefundFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置现金支付金额(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("cash_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("cash_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int? CashFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置现金退款金额(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("cash_refund_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("cash_refund_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int? CashRefundFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置优惠信息。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("promotion_detail")]
|
||||
[Newtonsoft.Json.JsonConverter(typeof(Converters.ResponsePropertyPromotionDetailNewtonsoftJsonConverter))]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("promotion_detail")]
|
||||
[System.Text.Json.Serialization.JsonConverter(typeof(Converters.ResponsePropertyPromotionDetailSystemTextJsonConverter))]
|
||||
public Types.PromotionDetail? PromotionDetail { get; set; }
|
||||
}
|
||||
}
|
@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
@ -49,7 +49,6 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("quantity")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("quantity")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int Quantity { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@ -57,7 +56,6 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("price")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("price")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int Price { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@ -74,7 +72,6 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("cost_price")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("cost_price")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int? CostPrice { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@ -156,6 +153,13 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置接口版本号。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("version")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("version")]
|
||||
public string? Version { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// <inheritdoc/>
|
||||
/// </summary>
|
||||
@ -203,7 +207,6 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int TotalFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /pay/queryexchagerate 接口的响应。</para>
|
||||
@ -45,7 +45,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("rate")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("rate")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public double? ExchangeRate { get; set; } = default!;
|
||||
}
|
||||
}
|
||||
|
@ -1,10 +1,17 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /pay/orderquery 接口的请求。</para>
|
||||
/// </summary>
|
||||
public class GetPayOrderRequest : WechatTenpaySignableRequest
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置接口版本号。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("version")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("version")]
|
||||
public string? Version { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// <inheritdoc/>
|
||||
/// </summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
@ -88,6 +88,140 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
[System.Text.Json.Serialization.JsonPropertyName("discount_detail")]
|
||||
public Types.DiscountDetail[]? DiscountList { get; set; }
|
||||
}
|
||||
|
||||
public class PromotionDetail
|
||||
{
|
||||
public static class Types
|
||||
{
|
||||
public class Promotion
|
||||
{
|
||||
public static class Types
|
||||
{
|
||||
public class GoodsDetail
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置商品编码。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("goods_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("goods_id")]
|
||||
public string GoodsId { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商品数量。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("quantity")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("quantity")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int Quantity { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商品单价(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("price")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("price")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int Price { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商品优惠金额(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("discount_amount")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("discount_amount")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int DiscountAmount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商品备注。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("goods_remark")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("goods_remark")]
|
||||
public string? GoodsRemark { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置券或者立减优惠 ID。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("promotion_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("promotion_id")]
|
||||
public string PromotionId { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置优惠名称。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("name")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("name")]
|
||||
public string? Name { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置优惠范围。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("scope")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("scope")]
|
||||
public string? Scope { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置优惠类型。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("type")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("type")]
|
||||
public string? Type { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置优惠券面额(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("amount")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("amount")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int Amount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置活动 ID。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("activity_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("activity_id")]
|
||||
public string? ActivityId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置微信出资(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("wxpay_contribute")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("wxpay_contribute")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int? WechatpayContribute { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商户出资(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("merchant_contribute")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("merchant_contribute")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int? MerchantContribute { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置其他出资(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("other_contribute")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("other_contribute")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int? OtherContribute { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置单品列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("goods_detail")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("goods_detail")]
|
||||
public Types.GoodsDetail[]? GoodsList { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置优惠信息列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("promotion_detail")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("promotion_detail")]
|
||||
public Types.Promotion[]? PromotionList { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
internal static class Converters
|
||||
@ -107,6 +241,14 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
internal class ResponsePropertyDetailSystemTextJsonConverter : System.Text.Json.Converters.TextualObjectInJsonFormatConverterBase<Types.Detail>
|
||||
{
|
||||
}
|
||||
|
||||
internal class ResponsePropertyPromotionDetailNewtonsoftJsonConverter : Newtonsoft.Json.Converters.TextualObjectInJsonFormatConverterBase<Types.PromotionDetail>
|
||||
{
|
||||
}
|
||||
|
||||
internal class ResponsePropertyPromotionDetailSystemTextJsonConverter : System.Text.Json.Converters.TextualObjectInJsonFormatConverterBase<Types.PromotionDetail>
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@ -303,5 +445,14 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
[System.Text.Json.Serialization.JsonPropertyName("detail")]
|
||||
[System.Text.Json.Serialization.JsonConverter(typeof(Converters.ResponsePropertyDetailSystemTextJsonConverter))]
|
||||
public Types.Detail? Detail { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置优惠信息。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("promotion_detail")]
|
||||
[Newtonsoft.Json.JsonConverter(typeof(Converters.ResponsePropertyPromotionDetailNewtonsoftJsonConverter))]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("promotion_detail")]
|
||||
[System.Text.Json.Serialization.JsonConverter(typeof(Converters.ResponsePropertyPromotionDetailSystemTextJsonConverter))]
|
||||
public Types.PromotionDetail? PromotionDetail { get; set; }
|
||||
}
|
||||
}
|
||||
|
@ -0,0 +1,64 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /pay/refundqueryv2 接口的请求。</para>
|
||||
/// </summary>
|
||||
public class GetPayRefundV2Request : WechatTenpaySignableRequest
|
||||
{
|
||||
/// <summary>
|
||||
/// <inheritdoc/>
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("mch_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("mch_id")]
|
||||
public override string? MerchantId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// <inheritdoc/>
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("appid")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("appid")]
|
||||
public override string? AppId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置子商户号。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("sub_mch_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("sub_mch_id")]
|
||||
public string? SubMerchantId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置子商户 AppId。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("sub_appid")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("sub_appid")]
|
||||
public string? SubAppId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商户订单号。与字段 <see cref="TransactionId"/>、<see cref="OutRefundNumber"/>、<see cref="RefundId"/> 四选一。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("out_trade_no")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("out_trade_no")]
|
||||
public string? OutTradeNumber { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置微信支付订单号。与字段 <see cref="OutTradeNumber"/>、<see cref="OutRefundNumber"/>、<see cref="RefundId"/> 四选一。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("transaction_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("transaction_id")]
|
||||
public string? TransactionId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商户退款单号。与字段 <see cref="OutTradeNumber"/>、<see cref="TransactionId"/>、<see cref="RefundId"/> 四选一。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("out_refund_no")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("out_refund_no")]
|
||||
public string? OutRefundNumber { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置微信退款单号。与字段 <see cref="OutTradeNumber"/>、<see cref="TransactionId"/>、<see cref="OutRefundNumber"/> 四选一。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refund_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refund_id")]
|
||||
public string? RefundId { get; set; }
|
||||
}
|
||||
}
|
@ -0,0 +1,226 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /pay/refundqueryv2 接口的响应。</para>
|
||||
/// </summary>
|
||||
public class GetPayRefundV2Response : WechatTenpaySignableResponse
|
||||
{
|
||||
public static class Types
|
||||
{
|
||||
public class PromotionDetail
|
||||
{
|
||||
public static class Types
|
||||
{
|
||||
public class Promotion
|
||||
{
|
||||
public static class Types
|
||||
{
|
||||
public class GoodsDetail
|
||||
{
|
||||
/// <summary>
|
||||
/// 获取或设置商品编码。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("goods_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("goods_id")]
|
||||
public string GoodsId { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商品单价(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("price")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("price")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int Price { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商品退款数量。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refund_quantity")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refund_quantity")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int RefundQuantity { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商品优惠退款金额(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refund_amount")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refund_amount")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int RefundAmount { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置券或者立减优惠 ID。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("promotion_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("promotion_id")]
|
||||
public string PromotionId { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置优惠名称。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("name")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("name")]
|
||||
public string? Name { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置优惠范围。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("scope")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("scope")]
|
||||
public string? Scope { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置优惠类型。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("type")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("type")]
|
||||
public string? Type { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置优惠券退款金额(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refund_amount")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refund_amount")]
|
||||
public int RefundAmount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置单品列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("goods_detail")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("goods_detail")]
|
||||
public Types.GoodsDetail[]? GoodsList { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置优惠信息列表。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("promotion_detail")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("promotion_detail")]
|
||||
public Types.Promotion[]? PromotionList { get; set; }
|
||||
}
|
||||
}
|
||||
|
||||
internal static class Converters
|
||||
{
|
||||
internal class ResponsePropertyPromotionDetailNewtonsoftJsonConverter : Newtonsoft.Json.Converters.TextualObjectInJsonFormatConverterBase<Types.PromotionDetail>
|
||||
{
|
||||
}
|
||||
|
||||
internal class ResponsePropertyPromotionDetailSystemTextJsonConverter : System.Text.Json.Converters.TextualObjectInJsonFormatConverterBase<Types.PromotionDetail>
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// <inheritdoc/>
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("mch_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("mch_id")]
|
||||
public override string? MerchantId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// <inheritdoc/>
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("appid")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("appid")]
|
||||
public override string? AppId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置子商户号。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("sub_mch_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("sub_mch_id")]
|
||||
public string? SubMerchantId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置子商户 AppId。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("sub_appid")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("sub_appid")]
|
||||
public string? SubAppId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商户订单号。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("out_trade_no")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("out_trade_no")]
|
||||
public string OutTradeNumber { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置微信支付订单号。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("transaction_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("transaction_id")]
|
||||
public string TransactionId { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置商户退款单号。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("out_refund_no")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("out_refund_no")]
|
||||
public string OutRefundNumber { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置微信退款单号。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refund_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refund_id")]
|
||||
public string RefundId { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置退款渠道。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refund_channel")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refund_channel")]
|
||||
public string? RefundChannel { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置退款状态。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refund_status")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refund_status")]
|
||||
public string RefundStatus { get; set; } = default!;
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置退款资金来源。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refund_account")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refund_account")]
|
||||
public string? RefundAccount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置退款入账账户。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refund_recv_accout")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refund_recv_accout")]
|
||||
public string? RefundReceiveAccount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置退款金额(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("refund_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("refund_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int RefundFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置现金退款金额(单位:分)。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("cash_refund_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("cash_refund_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int? CashRefundFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置优惠信息。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("promotion_detail")]
|
||||
[Newtonsoft.Json.JsonConverter(typeof(Converters.ResponsePropertyPromotionDetailNewtonsoftJsonConverter))]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("promotion_detail")]
|
||||
[System.Text.Json.Serialization.JsonConverter(typeof(Converters.ResponsePropertyPromotionDetailSystemTextJsonConverter))]
|
||||
public Types.PromotionDetail? PromotionDetail { get; set; }
|
||||
}
|
||||
}
|
@ -1,4 +1,4 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /mmpaymkttransfers/sendgroupredpack 接口的请求。</para>
|
||||
@ -59,7 +59,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_amount")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_amount")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int TotalAmount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@ -68,7 +67,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_num")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_num")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int TotalCount { get; set; } = 1;
|
||||
|
||||
/// <summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /mmpaymkttransfers/sendminiprogramhb 接口的请求。</para>
|
||||
@ -45,7 +45,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_amount")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_amount")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int TotalAmount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@ -54,7 +53,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_num")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_num")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int TotalCount { get; set; } = 1;
|
||||
|
||||
/// <summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /mmpaymkttransfers/sendredpack 接口的请求。</para>
|
||||
@ -59,7 +59,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_amount")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_amount")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int TotalAmount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@ -68,7 +67,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_num")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_num")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int TotalCount { get; set; } = 1;
|
||||
|
||||
/// <summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /mmpaymkttransfers/sendworkwxredpack 接口的请求。</para>
|
||||
@ -59,7 +59,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_amount")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_amount")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int TotalAmount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /mmpaymkttransfers/promotion/transfers 接口的请求。</para>
|
||||
@ -45,7 +45,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("amount")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("amount")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int Amount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@ -89,7 +88,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("brand_id")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("brand_id")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int? BrandId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /mmpaymkttransfers/promotion/paywwsptrans2pocket 接口的请求。</para>
|
||||
@ -52,7 +52,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("amount")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("amount")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int Amount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
/// <summary>
|
||||
/// <para>表示 [POST] /mmpaysptrans/pay_bank 接口的请求。</para>
|
||||
@ -31,7 +31,6 @@
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("amount")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("amount")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int Amount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
@ -43,8 +43,7 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("charging_time")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("charging_time")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int? ChargingTime { get; set; }
|
||||
public int? ChargingDuration { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置加油站名称。
|
||||
@ -79,7 +78,6 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("gas_amount")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("gas_amount")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int? GasAmount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@ -87,7 +85,6 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("gas_gun_no")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("gas_gun_no")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int? GasGunNumber { get; set; }
|
||||
|
||||
/// <summary>
|
||||
@ -109,11 +106,10 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("carrying_capacity")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("carrying_capacity")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int? CarryingCapacity { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 获取或设置核载区间。
|
||||
/// 获取或设置核载区间字符串。
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("carrying_range")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("carrying_range")]
|
||||
@ -203,7 +199,6 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("total_fee")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int TotalFee { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -1,4 +1,4 @@
|
||||
using System;
|
||||
using System;
|
||||
|
||||
namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
{
|
||||
@ -57,7 +57,6 @@ namespace SKIT.FlurlHttpClient.Wechat.TenpayV2.Models
|
||||
/// </summary>
|
||||
[Newtonsoft.Json.JsonProperty("free_time")]
|
||||
[System.Text.Json.Serialization.JsonPropertyName("free_time")]
|
||||
[System.Text.Json.Serialization.JsonNumberHandling(System.Text.Json.Serialization.JsonNumberHandling.AllowReadingFromString)]
|
||||
public int? FreeDuration { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
@ -0,0 +1,13 @@
|
||||
{
|
||||
"appid": "wx2421b1c4370ec43b",
|
||||
"mch_id": "10000100",
|
||||
"nonce_str": "6cefdb308e1e2e8aabd48cf79e546a02",
|
||||
"notify_url": "https://weixin.qq.com/",
|
||||
"out_refund_no": "1415701182",
|
||||
"out_trade_no": "1415757673",
|
||||
"refund_fee": "1",
|
||||
"total_fee": "1",
|
||||
"sign": "FE56DD4AA85C0EECA82C35595A69E153",
|
||||
"cash_refund_fee": "90",
|
||||
"detail": "{\"goods_detail\":[{\"goods_id\":\"商品编码\",\"wxpay_goods_id\":\"1001\",\"goods_name\":\"iPhone6s 16G\",\"refund_amount\":528800,\"refund_quantity\":1,\"price\":528800},{\"goods_id\":\"商品编码\",\"wxpay_goods_id\":\"1001\",\"goods_name\":\"iPhone6s 16G\",\"refund_amount\":528800,\"refund_quantity\":1,\"price\":608800}]}"
|
||||
}
|
@ -0,0 +1,18 @@
|
||||
{
|
||||
"return_code": "SUCCESS",
|
||||
"return_msg": "OK",
|
||||
"appid": "wx2421b1c4370ec43b",
|
||||
"mch_id": "10000100",
|
||||
"nonce_str": "NfsMFbUFpdbEhPXP",
|
||||
"sign": "B7274EB9F8925EB93100DD2085FA56C0",
|
||||
"result_code": "SUCCESS",
|
||||
"transaction_id": "1008450740201411110005820873",
|
||||
"out_trade_no": "1415757673",
|
||||
"out_refund_no": "1415701182",
|
||||
"refund_id": "2008450740201411110000174436",
|
||||
"total_fee": "1",
|
||||
"refund_fee": "1",
|
||||
"cash_fee": "1",
|
||||
"cash_refund_fee": "1",
|
||||
"promotion_detail": "{\"promotion_detail\":[{\"promotion_id\":\"109519\",\"scope\":\"SINGLE\",\"type\":\"DISCOUNT\",\"refund_amout\":5,\"goods_detail\":[{\"goods_id\":\"a_goods1\",\"refund_quantity\":7,\"price\":1,\"refund_amount\":4},{\"goods_id\":\"a_goods2\",\"refund_quantity\":1,\"price\":2,\"refund_amount\":1}]}]}"
|
||||
}
|
@ -0,0 +1,8 @@
|
||||
{
|
||||
"appid": "wx2421b1c4370ec43b",
|
||||
"mch_id": "10000100",
|
||||
"nonce_str": "0b9f35f484df17a732e537c37708d1d0",
|
||||
"out_refund_no": "123456789",
|
||||
"sub_mch_id": "1900000109",
|
||||
"sign": "66FFB727015F450D167EF38CCC549521"
|
||||
}
|
@ -0,0 +1,18 @@
|
||||
{
|
||||
"appid": "wx2421b1c4370ec43b",
|
||||
"mch_id": "10000100",
|
||||
"nonce_str": "TeqClE3i0mvn3DrK",
|
||||
"out_refund_no": "1415701182",
|
||||
"out_trade_no": "1415757673",
|
||||
"refund_fee": 3,
|
||||
"refund_id": "2008450740201411110000174436",
|
||||
"refund_status": "PROCESSING",
|
||||
"promotion_detail": "{\"promotion_detail\":[{\"promotion_id\":\"109519\",\"scope\":\"SINGLE\",\"type\":\"DISCOUNT\",\"refund_amount\":5,\"goods_detail\":[{\"goods_id\":\"a_goods1\",\"refund_quantity\":7,\"price\":1,\"refund_amount\":4},{\"goods_id\":\"a_goods2\",\"refund_quantity\":1,\"price\":2,\"refund_amount\":1}]}]}",
|
||||
"result_code": "SUCCESS",
|
||||
"return_code": "SUCCESS",
|
||||
"return_msg": "OK",
|
||||
"sign": "1F2841558E233C33ABA71A961D27561C",
|
||||
"refund_recv_accout": "1F2841558E233C33ABA71A961D27561C",
|
||||
"transaction_id": "1008450740201411110005820873",
|
||||
"cash_refund_fee": 90
|
||||
}
|
@ -1,4 +1,4 @@
|
||||
{
|
||||
{
|
||||
"mch_id": "10000098",
|
||||
"sub_mch_id": "10000100",
|
||||
"appid": "wxcbda96de0b165486",
|
||||
@ -12,5 +12,5 @@
|
||||
"notify_url": "http://yoursite.com/wxpay.html",
|
||||
"version": "3.0",
|
||||
"trade_scene": " PARKING",
|
||||
"scene_info": "{\"scene_info\":{\"start_time\":\"20170926114339\",\"end_time\":\"20170826114339\",\"charging_time\":\"3600\",\"free_time\":\"1200\",\"plate_number\":\"CB1000sdfasd\",\"car_type\":\"大型车\",\"parking_name\":\"欢乐海岸停车场\"}}"
|
||||
"scene_info": "{\"scene_info\":{\"start_time\":\"20170926114339\",\"end_time\":\"20170826114339\",\"charging_time\":3600,\"free_time\":1200,\"plate_number\":\"CB1000sdfasd\",\"car_type\":\"大型车\",\"parking_name\":\"欢乐海岸停车场\"}}"
|
||||
}
|
||||
|
@ -1,4 +1,4 @@
|
||||
{
|
||||
{
|
||||
"mch_id": "100000981",
|
||||
"sub_mch_id": "10000100",
|
||||
"appid": "wxcbda96de0b165486",
|
||||
@ -6,5 +6,5 @@
|
||||
"sign_type": "HMAC-SHA256",
|
||||
"trade_scene": "PARKING",
|
||||
"sign": "EE088059BBC9141264F8D14293AD6C4BB94CEA8C08AA98FBF93E262D445F8FF5",
|
||||
"scene_info": "{\"scene_info\":{\"start_time\":\"20170926114339\",\"plate_number\":\"CB1000sdfasd\",\"car_type\":\"大型车\",\"parking_name\":\"欢乐海岸停车场\",\"free_time\":\"1200\"}}"
|
||||
"scene_info": "{\"scene_info\":{\"start_time\":\"20170926114339\",\"plate_number\":\"CB1000sdfasd\",\"car_type\":\"大型车\",\"parking_name\":\"欢乐海岸停车场\",\"free_time\":1200}}"
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user