Add 'DNS Account Settings > Internal Views'

This commit is contained in:
2025-07-31 12:10:39 +02:00
parent 7e6607ae56
commit c5d0073e6d
14 changed files with 1127 additions and 4 deletions

View File

@@ -0,0 +1,34 @@
namespace AMWD.Net.Api.Cloudflare.Dns
{
/// <summary>
/// Represents a request to create an internal DNS view.
/// </summary>
public class CreateInternalDnsViewRequest
{
/// <summary>
/// Initializes a new instance of the <see cref="CreateInternalDnsViewRequest"/> class.
/// </summary>
/// <param name="accountId">The account identifier.</param>
/// <param name="name">The name of the view.</param>
public CreateInternalDnsViewRequest(string accountId, string name)
{
AccountId = accountId;
Name = name;
}
/// <summary>
/// The account identifier.
/// </summary>
public string AccountId { get; set; }
/// <summary>
/// The name of the view.
/// </summary>
public string Name { get; set; }
/// <summary>
/// The list of zones linked to this view.
/// </summary>
public IReadOnlyCollection<string> ZoneIds { get; set; } = [];
}
}

View File

@@ -0,0 +1,25 @@
namespace AMWD.Net.Api.Cloudflare.Dns
{
/// <summary>
/// Represents a request to update an internal DNS view.
/// </summary>
public class UpdateInternalDnsViewRequest : CreateInternalDnsViewRequest
{
/// <summary>
/// Initializes a new instance of the <see cref="UpdateInternalDnsViewRequest"/> class.
/// </summary>
/// <param name="accountId">The account identifier.</param>
/// <param name="viewId">The view identifier.</param>
/// <param name="name">The name of the view.</param>
public UpdateInternalDnsViewRequest(string accountId, string viewId, string name)
: base(accountId, name)
{
ViewId = viewId;
}
/// <summary>
/// The view identifier.
/// </summary>
public string ViewId { get; set; }
}
}