2021-04-13 10:36:49 +02:00
|
|
|
using System;
|
2022-01-24 20:17:09 +09:00
|
|
|
using System.ComponentModel;
|
2021-04-13 10:36:49 +02:00
|
|
|
using BTCPayServer.Client.JsonConverters;
|
|
|
|
using BTCPayServer.JsonConverters;
|
|
|
|
using BTCPayServer.Payments;
|
|
|
|
using Newtonsoft.Json;
|
|
|
|
|
|
|
|
namespace BTCPayServer.Data
|
|
|
|
{
|
|
|
|
public class PullPaymentBlob
|
|
|
|
{
|
|
|
|
public string Name { get; set; }
|
2022-02-09 21:54:00 -08:00
|
|
|
public string Description { get; set; }
|
2021-04-13 10:36:49 +02:00
|
|
|
public string Currency { get; set; }
|
|
|
|
public int Divisibility { get; set; }
|
|
|
|
[JsonConverter(typeof(NumericStringJsonConverter))]
|
|
|
|
public decimal Limit { get; set; }
|
|
|
|
[JsonConverter(typeof(NumericStringJsonConverter))]
|
|
|
|
public decimal MinimumClaim { get; set; }
|
|
|
|
public PullPaymentView View { get; set; } = new PullPaymentView();
|
|
|
|
[JsonConverter(typeof(TimeSpanJsonConverter.Seconds))]
|
|
|
|
public TimeSpan? Period { get; set; }
|
|
|
|
|
2022-01-24 20:17:09 +09:00
|
|
|
[DefaultValue(typeof(TimeSpan), "30.00:00:00")]
|
|
|
|
[JsonProperty(DefaultValueHandling = DefaultValueHandling.IgnoreAndPopulate)]
|
|
|
|
[JsonConverter(typeof(TimeSpanJsonConverter.Days))]
|
|
|
|
public TimeSpan BOLT11Expiration { get; set; }
|
|
|
|
|
|
|
|
|
2021-04-13 10:36:49 +02:00
|
|
|
[JsonProperty(ItemConverterType = typeof(PaymentMethodIdJsonConverter))]
|
|
|
|
public PaymentMethodId[] SupportedPaymentMethods { get; set; }
|
2021-12-31 16:59:02 +09:00
|
|
|
|
2022-04-28 02:51:04 +02:00
|
|
|
public bool AutoApproveClaims { get; set; }
|
|
|
|
|
2021-04-13 10:36:49 +02:00
|
|
|
public class PullPaymentView
|
|
|
|
{
|
|
|
|
public string Title { get; set; }
|
|
|
|
public string Description { get; set; }
|
|
|
|
public string EmbeddedCSS { get; set; }
|
|
|
|
public string Email { get; set; }
|
|
|
|
public string CustomCSSLink { get; set; }
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|