mirror of
https://github.com/logos-storage/logos-storage-nim-cs-dist-tests.git
synced 2026-01-08 16:33:07 +00:00
34 lines
882 B
C#
34 lines
882 B
C#
using Nethereum.Hex.HexConvertors.Extensions;
|
|
|
|
namespace TraceContract
|
|
{
|
|
public class Input
|
|
{
|
|
public string PurchaseId
|
|
{
|
|
get
|
|
{
|
|
var v = Environment.GetEnvironmentVariable("PURCHASE_ID");
|
|
if (!string.IsNullOrEmpty(v)) return v;
|
|
|
|
return
|
|
// expired:
|
|
"a7fe97dc32216aba0cbe74b87beb3f919aa116090dd5e0d48085a1a6b0080e82";
|
|
|
|
// started:
|
|
//"066df09a3a2e2587cfd577a0e96186c915b113d02b331b06e56f808494cff2b4";
|
|
}
|
|
}
|
|
|
|
public byte[] RequestId
|
|
{
|
|
get
|
|
{
|
|
var r = PurchaseId.HexToByteArray();
|
|
if (r == null || r.Length != 32) throw new ArgumentException(nameof(PurchaseId));
|
|
return r;
|
|
}
|
|
}
|
|
}
|
|
}
|