Compare commits
1
Commits
0f1d3dadb0
..
master
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
07e243964f |
@@ -157,6 +157,20 @@ namespace xIdentityModels.Extensions
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Validate ...
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="source"></param>
|
||||||
|
/// <returns></returns>
|
||||||
|
public static bool IsValid(this XCreateApiKeyRequest source)
|
||||||
|
{
|
||||||
|
//
|
||||||
|
var result = !source.IsNull();
|
||||||
|
|
||||||
|
//
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Validate Item for Add or Update ...
|
/// Validate Item for Add or Update ...
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@@ -0,0 +1,16 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
|
||||||
|
namespace xIdentityModels.Models
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Create Specified Api Key ...
|
||||||
|
/// </summary>
|
||||||
|
public class XCreateApiKeyRequest
|
||||||
|
{
|
||||||
|
public int? RateLimit {get; set;} = null;
|
||||||
|
public TimeSpan? Expiration {get; set;} = null;
|
||||||
|
public IEnumerable<string> Scopes {get; set;} = null;
|
||||||
|
public IEnumerable<string> AllowedIPs {get; set;} = null;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
using System;
|
||||||
|
|
||||||
|
namespace xIdentityModels.Models
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
/// Rotate Specified Api Key ...
|
||||||
|
/// </summary>
|
||||||
|
public class XRotateApiKeyRequest
|
||||||
|
{
|
||||||
|
public TimeSpan? NewExpiration { get; set; } = null;
|
||||||
|
}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user