Skip to content

Commit c7526ee

Browse files
authored
feat(dom): add more filters on ListDNSZones to ease VPC sync (#850)
1 parent 2335da8 commit c7526ee

File tree

2 files changed

+21
-2
lines changed

2 files changed

+21
-2
lines changed

packages/clients/src/api/domain/v2beta1/api.gen.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,10 @@ export class API extends ParentAPI {
171171
method: 'GET',
172172
path: `/domain/v2beta1/dns-zones`,
173173
urlParams: urlParams(
174+
['created_after', request.createdAfter],
175+
['created_before', request.createdBefore],
174176
['dns_zone', request.dnsZone],
177+
['dns_zones', request.dnsZones],
175178
['domain', request.domain],
176179
['order_by', request.orderBy ?? 'domain_asc'],
177180
['organization_id', request.organizationId],
@@ -181,6 +184,8 @@ export class API extends ParentAPI {
181184
request.pageSize ?? this.client.settings.defaultPageSize,
182185
],
183186
['project_id', request.projectId],
187+
['updated_after', request.updatedAfter],
188+
['updated_before', request.updatedBefore],
184189
),
185190
},
186191
unmarshalListDNSZonesResponse,

packages/clients/src/api/domain/v2beta1/types.gen.ts

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,10 @@ export type ListDNSZonesRequestOrderBy =
147147
| 'domain_desc'
148148
| 'subdomain_asc'
149149
| 'subdomain_desc'
150+
| 'created_at_asc'
151+
| 'created_at_desc'
152+
| 'updated_at_asc'
153+
| 'updated_at_desc'
150154

151155
export type ListDomainsRequestOrderBy = 'domain_asc' | 'domain_desc'
152156

@@ -848,8 +852,18 @@ export type ListDNSZonesRequest = {
848852
pageSize?: number
849853
/** Domain on which to filter the returned DNS zones. */
850854
domain: string
851-
/** DNS zone on which to filter the returned DNS zones. */
852-
dnsZone: string
855+
/** @deprecated DNS zone on which to filter the returned DNS zones. */
856+
dnsZone?: string
857+
/** DNS zones on which to filter the returned DNS zones. */
858+
dnsZones?: string[]
859+
/** Only list DNS zones created after this date. */
860+
createdAfter?: Date
861+
/** Only list DNS zones created before this date. */
862+
createdBefore?: Date
863+
/** Only list DNS zones updated after this date. */
864+
updatedAfter?: Date
865+
/** Only list DNS zones updated before this date. */
866+
updatedBefore?: Date
853867
}
854868

855869
export type CreateDNSZoneRequest = {

0 commit comments

Comments
 (0)