-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathapi.ts
1602 lines (1449 loc) · 87.3 KB
/
api.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
// NOTE: GENERATED by github.com/mjl-/sherpats, DO NOT MODIFY
namespace api {
// Zone for which DNS records are managed, for which a delegation with NS records
// exists. Commonly called "domains". Subdomains are not necessarily zones, they
// are just names with dots in a zone.
export interface Zone {
Name: string // Absolute name with trailing dot. In lower-case form.
ProviderConfigName: string
SerialLocal: number // Locally known serial. Will be 0 for newly created zones. Can be different from SerialRemote since not all name servers change serials on zone changes.
SerialRemote: number // Serial as known at remote. Used during refresh to decide whether to sync. Not meaningful when <= 1 (e.g. always for AWS Route53).
LastSync?: Date | null // Last time an attempt to sync was made. Used for periodic sync.
LastRecordChange?: Date | null // Last time a change in records was detected.
SyncInterval: number // Time between automatic synchronizations by getting all records.
RefreshInterval: number // Time between zone refresh: checks for an updated SOA record (after which a sync is initiated). After a detected record change, checks are done more often. For 1 RefreshInterval, during the first 1/10th of time, a check is done 5 times. For the remaining 9/10th of time, a check is also done every 10 times.
NextSync: Date
NextRefresh: Date
}
export interface ProviderConfig {
Name: string
ProviderName: string // Name of a libdns package.
ProviderConfigJSON: string // JSON encoding of the "Provider" type from the libdns package referenced by ProviderName.
}
// ZoneNotify is an address to DNS NOTIFY when a change to the zone is discovered.
export interface ZoneNotify {
ID: number
Created: Date
Zone: string
Address: string // E.g. 127.0.0.1:53
Protocol: string // "tcp" or "udp"
}
// Credential is used for TSIG or mutual TLS authentication during DNS.
export interface Credential {
ID: number
Created: Date
Name: string // Without trailing dot for TSIG, we add it during DNS. rfc/8945:245
Type: string // "tsig" or "tlspubkey"
TSIGSecret: string // Base64-encoded.
TLSPublicKey: string // Raw-url-base64-encoded SHA-256 hash of TLS certificate subject public key info ("SPKI").
}
// RecordSet holds the records (values) for a name and type, and optionally
// historic state of the records over time.
export interface RecordSet {
Records?: Record[] | null // Always at least one record. All with the same name, type and ttl. Sorted by value.
States?: PropagationState[] | null // Filled with either the full historic propagation state including the current/latest value (when returned by ZoneRecordSetHistory), or only those propagation states that are not the current value but may still be relevant (may still be in DNS caches).
}
// Record is a DNS record that discovered through the API of the provider.
export interface Record {
ID: number
Zone: string // Name of zone, lower-case.
SerialFirst: number // Serial where this record first appeared. For SOA records, this is equal to its Serial field.
SerialDeleted: number // Serial when record was removed. For future IXFR.
First: Date
Deleted?: Date | null
AbsName: string // Fully qualified, in lower-case.
Type: number // eg A, etc.
Class: number
TTL: number
DataHex: string
Value: string // Human-readable.
ProviderID: string // From libdns.
}
// PropagationState indicates value(s) of a record set in a period, or that a
// negative lookup result may be cached somewhere.
export interface PropagationState {
Start: Date
End?: Date | null // If nil, then still active.
Negative: boolean // If true, this state represents a period during which a negative lookup result may be cached. Records will be nil.
Records?: Record[] | null // Records active during the period Start-End.
}
// RecordSetChange is a new or updated record set.
export interface RecordSetChange {
RelName: string
TTL: number
Type: number
Values?: string[] | null
}
// KnownProviders ensures all providers types are included in sherpadoc API documentation.
export interface KnownProviders {
Xalidns: Provider_alidns
Xautodns: Provider_autodns
Xazure: Provider_azure
Xbunny: Provider_bunny
Xcivo: Provider_civo
Xcloudflare: Provider_cloudflare
Xcloudns: Provider_cloudns
Xddnss: Provider_ddnss
Xdesec: Provider_desec
Xdigitalocean: Provider_digitalocean
Xdirectadmin: Provider_directadmin
Xdnsimple: Provider_dnsimple
Xdnsmadeeasy: Provider_dnsmadeeasy
Xdnspod: Provider_dnspod
Xdnsupdate: Provider_dnsupdate
Xdomainnameshop: Provider_domainnameshop
Xdreamhost: Provider_dreamhost
Xduckdns: Provider_duckdns
Xdynu: Provider_dynu
Xdynv6: Provider_dynv6
Xeasydns: Provider_easydns
Xexoscale: Provider_exoscale
Xgandi: Provider_gandi
Xgcore: Provider_gcore
Xglesys: Provider_glesys
Xgodaddy: Provider_godaddy
Xgoogleclouddns: Provider_googleclouddns
Xhe: Provider_he
Xhetzner: Provider_hetzner
Xhexonet: Provider_hexonet
Xhosttech: Provider_hosttech
Xhuaweicloud: Provider_huaweicloud
Xinfomaniak: Provider_infomaniak
Xinwx: Provider_inwx
Xionos: Provider_ionos
Xkatapult: Provider_katapult
Xleaseweb: Provider_leaseweb
Xlinode: Provider_linode
Xloopia: Provider_loopia
Xluadns: Provider_luadns
Xmailinabox: Provider_mailinabox
Xmetaname: Provider_metaname
Xmijnhost: Provider_mijnhost
Xmythicbeasts: Provider_mythicbeasts
Xnamecheap: Provider_namecheap
Xnamedotcom: Provider_namedotcom
Xnamesilo: Provider_namesilo
Xnanelo: Provider_nanelo
Xnetcup: Provider_netcup
Xnetlify: Provider_netlify
Xnfsn: Provider_nfsn
Xnjalla: Provider_njalla
Xopenstackdesignate: Provider
Xovh: Provider_ovh
Xporkbun: Provider_porkbun
Xpowerdns: Provider_powerdns
Xrfc2136: Provider_rfc2136
Xroute53: Provider_route53
Xscaleway: Provider_scaleway
Xselectel: Provider_selectel
Xtencentcloud: Provider_tencentcloud
Xtimeweb: Provider_timeweb
Xtotaluptime: Provider_totaluptime
Xvultr: Provider_vultr
Xwestcn: Provider_westcn
}
// Provider implements the libdns interfaces for Alicloud.
export interface Provider_alidns {
access_key_id: string // The API Key ID Required by Aliyun's for accessing the Aliyun's API
access_key_secret: string // The API Key Secret Required by Aliyun's for accessing the Aliyun's API
region_id?: string | null // Optional for identifing the region of the Aliyun's Service,The default is zh-hangzhou
}
// Provider facilitates DNS record manipulation with Autodns.
export interface Provider_autodns {
username: string
password: string
Endpoint: string
context: string
primary: string
}
// Provider implements the libdns interfaces for Azure DNS
export interface Provider_azure {
subscription_id?: string | null // Subscription ID is the ID of the subscription in which the DNS zone is located. Required.
resource_group_name?: string | null // Resource Group Name is the name of the resource group in which the DNS zone is located. Required.
tenant_id?: string | null // (Optional) Tenant ID is the ID of the tenant of the Microsoft Entra ID in which the application is located. Required only when authenticating using a service principal with a secret. Do not set any value to authenticate using a managed identity.
client_id?: string | null // (Optional) Client ID is the ID of the application. Required only when authenticating using a service principal with a secret. Do not set any value to authenticate using a managed identity.
client_secret?: string | null // (Optional) Client Secret is the client secret of the application. Required only when authenticating using a service principal with a secret. Do not set any value to authenticate using a managed identity.
}
// Provider facilitates DNS record manipulation with Bunny.net
export interface Provider_bunny {
access_key: string // AccessKey is the Bunny.net API key - see https://docs.bunny.net/reference/bunnynet-api-overview
debug: boolean
}
export interface Provider_civo {
api_token?: string | null
}
// Provider implements the libdns interfaces for Cloudflare.
// TODO: Support pagination and retries, handle rate limits.
export interface Provider_cloudflare {
api_token?: string | null // API tokens are used for authentication. Make sure to use scoped API **tokens**, NOT a global API **key**.; API token with Zone.DNS:Write (can be scoped to single Zone if ZoneToken is also provided)
zone_token?: string | null // Optional Zone:Read token (global scope)
}
// Provider facilitates DNS record manipulation with ClouDNS.
export interface Provider_cloudns {
auth_id: string
sub_auth_id?: string | null
auth_password: string
}
// Provider facilitates DNS record manipulation with ddnss.
export interface Provider_ddnss {
api_token: string
username?: string | null
password?: string | null
}
// Provider facilitates DNS record manipulation with deSEC.
export interface Provider_desec {
token?: string | null // Token is a token created on https://desec.io/tokens. A basic token without the permission to manage tokens is sufficient.
}
// Provider implements the libdns interfaces for DigitalOcean
export interface Provider_digitalocean {
auth_token: string // APIToken is the DigitalOcean API token - see https://www.digitalocean.com/docs/apis-clis/api/create-personal-access-token/
}
// Provider facilitates DNS record manipulation with DirectAdmin.
export interface Provider_directadmin {
host?: string | null // ServerURL should be the hostname (with port if necessary) of the DirectAdmin instance you are trying to use
user?: string | null // User should be the DirectAdmin username that the Login Key is created under
login_key?: string | null // LoginKey is used for authentication The key will need two permissions: `CMD_API_SHOW_DOMAINS` `CMD_API_DNS_CONTROL` Unless you are only using `GetRecords()`, in which case `CMD_API_DNS_CONTROL` can be omitted
insecure_requests?: boolean | null // InsecureRequests is an optional parameter used to ignore SSL related errors on the DirectAdmin host
debug?: string | null // Debug - can set this to stdout or stderr to dump debugging information about the API interaction with powerdns. This will dump your auth token in plain text so be careful.
}
// Provider facilitates DNS record manipulation with DNSimple.
export interface Provider_dnsimple {
api_access_token?: string | null
account_id?: string | null
api_url?: string | null
}
// Provider facilitates DNS record manipulation with DNSMadeEasy
export interface Provider_dnsmadeeasy {
api_key?: string | null
secret_key?: string | null
api_endpoint?: BaseURL | null
}
// Provider implements the libdns interfaces for DNSPOD
export interface Provider_dnspod {
auth_token: string // APIToken is the DNSPOD API token - see https://www.dnspod.cn/docs/info.html#common-parameters
}
// Provider facilitates DNS record manipulation with the DNS UPDATE protocol.
export interface Provider_dnsupdate {
addr?: string | null // DNS server address
}
// Provider facilitates DNS record manipulation with Domainnameshop
// https://api.domeneshop.no/docs/#section/Authentication
export interface Provider_domainnameshop {
api_token: string
api_secret: string
}
// Provider facilitates DNS record manipulation with Dreamhost.
export interface Provider_dreamhost {
api_key?: string | null
}
// Provider implements the libdns interfaces for Duck DNS.
export interface Provider_duckdns {
api_token?: string | null
override_domain?: string | null
}
// Provider facilitates DNS record manipulation with dynu.
export interface Provider_dynu {
api_token?: string | null // config fields (with snake_case json struct tags on exported fields)
own_domain?: string | null
}
// Provider for dynv6 HTTP REST API
export interface Provider_dynv6 {
token?: string | null // Token is required for authorization. You can generate one at: https://dynv6.com/keys
}
// Provider facilitates DNS record manipulation with EasyDNS.
export interface Provider_easydns {
api_token?: string | null // EasyDNS API Token (required)
api_key?: string | null // EasyDNS API Key (required)
api_url?: string | null // EasyDNS API URL (defaults to https://rest.easydns.net)
}
// Provider facilitates DNS record manipulation with Exoscale.
export interface Provider_exoscale {
api_key?: string | null // Exoscale API Key (required)
api_secret?: string | null // Exoscale API Secret (required)
}
// Provider implements the libdns interfaces for Gandi.
export interface Provider_gandi {
bearer_token?: string | null
}
// Provider facilitates DNS record manipulation with GCore DNS.
export interface Provider_gcore {
api_key?: string | null
}
export interface Provider_glesys {
project?: string | null
api_key?: string | null
}
// Provider godaddy dns provider
export interface Provider_godaddy {
api_token?: string | null
}
// Provider facilitates DNS record manipulation with Google Cloud DNS.
export interface Provider_googleclouddns {
gcp_project?: string | null
gcp_application_default?: string | null
}
// Provider facilitates DNS record manipulation with Hurricane Electric.
export interface Provider_he {
api_key?: string | null // Hurricane Electric DDNS key to use for authentication when modifying DNS records.
}
// Provider implements the libdns interfaces for Hetzner
export interface Provider_hetzner {
auth_api_token: string // AuthAPIToken is the Hetzner Auth API token - see https://dns.hetzner.com/api-docs#section/Authentication/Auth-API-Token
}
// Provider facilitates DNS record manipulation with Hexonet.
export interface Provider_hexonet {
username: string
password?: string | null
debug?: string | null // Debug - can set this to stdout or stderr to dump debugging information about the API interaction with hexonet. This will dump your auth token in plain text so be careful.
}
// Provider facilitates DNS record manipulation with Hosttech.ch.
export interface Provider_hosttech {
api_token?: string | null
}
// Provider facilitates DNS record manipulation with Huawei Cloud
export interface Provider_huaweicloud {
access_key_id?: string | null // AccessKeyId is required by the Huawei Cloud API for authentication.
secret_access_key?: string | null // SecretAccessKey is required by the Huawei Cloud API for authentication.
region_id?: string | null // RegionId is optional and defaults to "cn-south-1".
}
// Provider facilitates DNS record manipulation with infomaniak.
export interface Provider_infomaniak {
api_token?: string | null // infomaniak API token
}
// Provider facilitates DNS record manipulation with INWX.
export interface Provider_inwx {
username?: string | null // Username of your INWX account.
password?: string | null // Password of your INWX account.
shared_secret?: string | null // The shared secret is used to generate a TAN if you have activated "Mobile TAN" for your INWX account.
endpoint_url?: string | null // URL of the JSON-RPC API endpoint. It defaults to the production endpoint.
}
// Provider implements the libdns interfaces for IONOS
export interface Provider_ionos {
auth_api_token: string // AuthAPIToken is the IONOS Auth API token - see https://dns.ionos.com/api-docs#section/Authentication/Auth-API-Token
}
// Provider facilitates DNS record manipulation with Katapult.
export interface Provider_katapult {
api_token?: string | null
}
// Provider facilitates DNS record manipulation with Leaseweb.
export interface Provider_leaseweb {
api_token?: string | null // Leasewebs API key. Generate one in the Leaseweb customer portal -> Administration -> API Key
}
// Provider facilitates DNS record manipulation with Linode.
export interface Provider_linode {
api_token?: string | null // APIToken is the Linode Personal Access Token, see https://cloud.linode.com/profile/tokens.
api_url?: string | null // APIURL is the Linode API hostname, i.e. "api.linode.com".
api_version?: string | null // APIVersion is the Linode API version, i.e. "v4".
}
// Provider facilitates DNS record manipulation with Loopia.
export interface Provider_loopia {
username?: string | null
password?: string | null
customer?: string | null
}
// Provider facilitates DNS record manipulation with LuaDNS.
export interface Provider_luadns {
email?: string | null
api_key?: string | null
}
// Provider facilitates DNS record manipulation with Mail-In-A-Box.
export interface Provider_mailinabox {
api_url?: string | null // APIURL is the URL provided by the mailinabox admin interface, found on your box here: https://box.[your-domain.com]/admin#custom_dns https://box.[your-domain.com]/admin/dns/custom
email_address?: string | null // EmailAddress of an admin account. It's recommended that a dedicated account be created especially for managing DNS.
password?: string | null // Password of the admin account that corresponds to the email.
}
// Provider facilitates DNS record manipulation with Metaname
export interface Provider_metaname {
api_key?: string | null
account_reference?: string | null
endpoint?: string | null
}
// Provider facilitates DNS record manipulation with mijn.host.
export interface Provider_mijnhost {
api_token?: string | null
}
// Provider facilitates DNS record manipulation with Mythic Beasts.
export interface Provider_mythicbeasts {
key_id?: string | null
secret?: string | null
}
// Provider facilitates DNS record manipulation with namecheap.
// The libdns methods that return updated structs do not have
// their ID fields set since this information is not returned
// by the namecheap API.
export interface Provider_namecheap {
api_key?: string | null // APIKey is your namecheap API key. See: https://www.namecheap.com/support/api/intro/ for more details.
user?: string | null // User is your namecheap API user. This can be the same as your username.
api_endpoint?: string | null // APIEndpoint to use. If testing, you can use the "sandbox" endpoint instead of the production one.
client_ip?: string | null // ClientIP is the IP address of the requesting client. If this is not set, a discovery service will be used to determine the public ip of the machine. You must first whitelist your IP in the namecheap console before using the API.
}
// Provider implements the libdns interface for namedotcom
export interface Provider_namedotcom {
api_token?: string | null
user?: string | null
server?: string | null // e.g. https://api.name.com or https://api.dev.name.com
}
// Provider facilitates DNS record manipulation with Namesilo.
export interface Provider_namesilo {
api_token?: string | null
}
// Provider facilitates DNS record manipulation with Nanelo
export interface Provider_nanelo {
api_token?: string | null
}
// Provider facilitates DNS record manipulation with netcup.
// CustomerNumber, APIKey and APIPassword have to be filled with the respective credentials from netcup.
// The netcup API requires a session ID for all requests, so at the beginning of each method call
// a login is performed to receive the session ID and at the end the session is stopped with a logout.
// The mutex locks concurrent access on all four implemented methods to make sure there is
// no race condition in the netcup zone and record configuration.
export interface Provider_netcup {
customer_number: string
api_key: string
api_password: string
}
// Provider implements the libdns interfaces for Netlify.
export interface Provider_netlify {
personal_access_token?: string | null // Personal Access Token is required to Authenticate yourself to Netlify's API
}
// Provider facilitates DNS record manipulation with nearlyfreespeech.net
export interface Provider_nfsn {
login?: string | null // NFSN Member Login.
api_key?: string | null // NFSN API Key. API Keys can be generated from the "Profile" tab in the NFSN member interface.
}
export interface Provider_njalla {
api_token?: string | null
}
// Provider implements the libdns interfaces for OpenStack Designate.
export interface Provider {
auth_open_stack: AuthOpenStack
}
// AuthOpenStack contains credentials for OpenStack Designate.
export interface AuthOpenStack {
region_name: string
tenant_id: string
identity_api_version: string
password: string
auth_url: string
username: string
tenant_name: string
endpoint_type: string
}
// Provider facilitates DNS record manipulation with OVH.
export interface Provider_ovh {
endpoint?: string | null
application_key?: string | null
application_secret?: string | null
consumer_key?: string | null
}
// Provider facilitates DNS record manipulation with Porkbun.
export interface Provider_porkbun {
api_key?: string | null
api_secret_key?: string | null
}
// Provider facilitates DNS record manipulation with PowerDNS.
export interface Provider_powerdns {
server_url: string // ServerURL is the location of the pdns server.
server_id?: string | null // ServerID is the id of the server. localhost will be used if this is omitted.
api_token?: string | null // APIToken is the auth token.
debug?: string | null // Debug - can set this to stdout or stderr to dump debugging information about the API interaction with powerdns. This will dump your auth token in plain text so be careful.
}
export interface Provider_rfc2136 {
key_name?: string | null
key_alg?: string | null
key?: string | null
server?: string | null
}
// Provider implements the libdns interfaces for Route53.
//
// By default, the provider loads the AWS configuration from the environment.
// To override these values, set the fields in the Provider struct.
export interface Provider_route53 {
region?: string | null // Region is the AWS Region to use. If not set, it will use AWS_REGION environment variable.
aws_profile?: string | null // AWSProfile is the AWS Profile to use. If not set, it will use AWS_PROFILE environment variable. Deprecated: Use Profile instead
profile?: string | null // AWSProfile is the AWS Profile to use. If not set, it will use AWS_PROFILE environment variable.
access_key_id?: string | null // AccessKeyId is the AWS Access Key ID to use. If not set, it will use AWS_ACCESS_KEY_ID
secret_access_key?: string | null // SecretAccessKey is the AWS Secret Access Key to use. If not set, it will use AWS_SECRET_ACCESS_KEY environment variable.
token?: string | null // Token is the AWS Session Token to use. If not set, it will use AWS_SESSION_TOKEN environment variable. Deprecated: Use SessionToken instead.
session_token?: string | null // SessionToken is the AWS Session Token to use. If not set, it will use AWS_SESSION_TOKEN environment variable.
max_retries?: number | null // MaxRetries is the maximum number of retries to make when a request fails. If not set, it will use 5 retries.
max_wait_dur?: number | null // MaxWaitDur is the maximum amount of time in seconds to wait for a record to be propagated. If not set, it will 1 minute.
wait_for_propagation?: boolean | null // WaitForPropagation if set to true, it will wait for the record to be propagated before returning.
hosted_zone_id?: string | null // HostedZoneID is the ID of the hosted zone to use. If not set, it will be discovered from the zone name. This option should contain only the ID; the "/hostedzone/" prefix will be added automatically.
}
export interface Provider_scaleway {
secret_key?: string | null
organization_id?: string | null
}
// Provider facilitates DNS record manipulation with <TODO: PROVIDER NAME>.
export interface Provider_selectel {
user?: string | null
password?: string | null
account_id?: string | null
project_name?: string | null
KeystoneToken: string
}
// Provider is a libdns provider for Tencent Cloud DNS
export interface Provider_tencentcloud {
SecretId: string // SecretId is the secret ID for Tencent Cloud DNS
SecretKey: string // SecretKey is the secret key for Tencent Cloud DNS
}
export interface Provider_timeweb {
ApiURL: string
ApiToken: string
}
// Provider facilitates DNS record manipulation with Total Uptime.
export interface Provider_totaluptime {
username?: string | null
password?: string | null
}
// Provider implements the libdns interfaces for Vultr
// Adapted from libdns/digitalocean to work with the Vultr API
export interface Provider_vultr {
api_token?: string | null // APIToken is the Vultr API token see https://my.vultr.com/settings/#settingsapi
}
// Provider facilitates DNS record manipulation with west.cn.
export interface Provider_westcn {
username?: string | null // Username is your username for west.cn, see https://www.west.cn/CustomerCenter/doc/apiv2.html#12u3001u8eabu4efdu9a8cu8bc10a3ca20id3d12u3001u8eabu4efdu9a8cu8bc13e203ca3e
api_password?: string | null // APIPassword is your API password for west.cn, see https://www.west.cn/CustomerCenter/doc/apiv2.html#12u3001u8eabu4efdu9a8cu8bc10a3ca20id3d12u3001u8eabu4efdu9a8cu8bc13e203ca3e
}
// Section represents documentation about a Sherpa API section, as returned by the "_docs" function.
export interface sherpadocSection {
Name: string // Name of an API section.
Docs: string // Explanation of the API in text or markdown.
Functions?: (sherpadocFunction | null)[] | null // Functions in this section.
Sections?: (sherpadocSection | null)[] | null // Subsections, each with their own documentation.
Structs?: sherpadocStruct[] | null // Structs as named types.
Ints?: sherpadocInts[] | null // Int enums as named types.
Strings?: sherpadocStrings[] | null // String enums used as named types.
Version?: string | null // Version if this API, only relevant for the top-level section of an API. Typically filled in by server at startup.
SherpaVersion: number // Version of sherpa this API implements. Currently at 0. Typically filled in by server at startup.
SherpadocVersion?: number | null // Version of the sherpadoc format. Currently at 1, the first defined version. Only relevant for the top-level section of an API.
}
// Function contains the documentation for a single function.
export interface sherpadocFunction {
Name: string // Name of the function.
Docs: string // Text or markdown, describing the function, its parameters, return types and possible errors.
Params?: sherpadocArg[] | null
Returns?: sherpadocArg[] | null
}
// Arg is the name and type of a function parameter or return value.
//
// Production rules:
//
// basictype := "bool" | "int8", "uint8" | "int16" | "uint16" | "int32" | "uint32" | "int64" | "uint64" | "int64s" | "uint64s" | "float32" | "float64" | "string" | "timestamp"
// array := "[]"
// map := "{}"
// identifier := [a-zA-Z][a-zA-Z0-9]*
// type := "nullable"? ("any" | basictype | identifier | array type | map type)
//
// It is not possible to have inline structs in an Arg. Those must be encoded as a
// named type.
export interface sherpadocArg {
Name: string // Name of the argument.
Typewords?: string[] | null // Typewords is an array of tokens describing the type.
}
// Struct is a named compound type.
export interface sherpadocStruct {
Name: string
Docs: string
Fields?: sherpadocField[] | null
}
// Field is a single field of a struct type.
// The type can reference another named type.
export interface sherpadocField {
Name: string
Docs: string
Typewords?: string[] | null
}
// Ints is a type representing an enum with integers as types.
export interface sherpadocInts {
Name: string
Docs: string
Values?: IntValue[] | null
}
export interface IntValue {
Name: string
Value: number
Docs: string
}
// Strings is a type representing an enum with strings as values.
export interface sherpadocStrings {
Name: string
Docs: string
Values?: StringValue[] | null
}
export interface StringValue {
Name: string
Value: string
Docs: string
}
export enum BaseURL {
Sandbox = "https://api.sandbox.dnsmadeeasy.com/V2.0/",
Prod = "https://api.dnsmadeeasy.com/V2.0/",
}
export const structTypes: {[typename: string]: boolean} = {"AuthOpenStack":true,"Credential":true,"IntValue":true,"KnownProviders":true,"PropagationState":true,"Provider":true,"ProviderConfig":true,"Provider_alidns":true,"Provider_autodns":true,"Provider_azure":true,"Provider_bunny":true,"Provider_civo":true,"Provider_cloudflare":true,"Provider_cloudns":true,"Provider_ddnss":true,"Provider_desec":true,"Provider_digitalocean":true,"Provider_directadmin":true,"Provider_dnsimple":true,"Provider_dnsmadeeasy":true,"Provider_dnspod":true,"Provider_dnsupdate":true,"Provider_domainnameshop":true,"Provider_dreamhost":true,"Provider_duckdns":true,"Provider_dynu":true,"Provider_dynv6":true,"Provider_easydns":true,"Provider_exoscale":true,"Provider_gandi":true,"Provider_gcore":true,"Provider_glesys":true,"Provider_godaddy":true,"Provider_googleclouddns":true,"Provider_he":true,"Provider_hetzner":true,"Provider_hexonet":true,"Provider_hosttech":true,"Provider_huaweicloud":true,"Provider_infomaniak":true,"Provider_inwx":true,"Provider_ionos":true,"Provider_katapult":true,"Provider_leaseweb":true,"Provider_linode":true,"Provider_loopia":true,"Provider_luadns":true,"Provider_mailinabox":true,"Provider_metaname":true,"Provider_mijnhost":true,"Provider_mythicbeasts":true,"Provider_namecheap":true,"Provider_namedotcom":true,"Provider_namesilo":true,"Provider_nanelo":true,"Provider_netcup":true,"Provider_netlify":true,"Provider_nfsn":true,"Provider_njalla":true,"Provider_ovh":true,"Provider_porkbun":true,"Provider_powerdns":true,"Provider_rfc2136":true,"Provider_route53":true,"Provider_scaleway":true,"Provider_selectel":true,"Provider_tencentcloud":true,"Provider_timeweb":true,"Provider_totaluptime":true,"Provider_vultr":true,"Provider_westcn":true,"Record":true,"RecordSet":true,"RecordSetChange":true,"StringValue":true,"Zone":true,"ZoneNotify":true,"sherpadocArg":true,"sherpadocField":true,"sherpadocFunction":true,"sherpadocInts":true,"sherpadocSection":true,"sherpadocStrings":true,"sherpadocStruct":true}
export const stringsTypes: {[typename: string]: boolean} = {"BaseURL":true}
export const intsTypes: {[typename: string]: boolean} = {}
export const types: TypenameMap = {
"Zone": {"Name":"Zone","Docs":"","Fields":[{"Name":"Name","Docs":"","Typewords":["string"]},{"Name":"ProviderConfigName","Docs":"","Typewords":["string"]},{"Name":"SerialLocal","Docs":"","Typewords":["uint32"]},{"Name":"SerialRemote","Docs":"","Typewords":["uint32"]},{"Name":"LastSync","Docs":"","Typewords":["nullable","timestamp"]},{"Name":"LastRecordChange","Docs":"","Typewords":["nullable","timestamp"]},{"Name":"SyncInterval","Docs":"","Typewords":["int64"]},{"Name":"RefreshInterval","Docs":"","Typewords":["int64"]},{"Name":"NextSync","Docs":"","Typewords":["timestamp"]},{"Name":"NextRefresh","Docs":"","Typewords":["timestamp"]}]},
"ProviderConfig": {"Name":"ProviderConfig","Docs":"","Fields":[{"Name":"Name","Docs":"","Typewords":["string"]},{"Name":"ProviderName","Docs":"","Typewords":["string"]},{"Name":"ProviderConfigJSON","Docs":"","Typewords":["string"]}]},
"ZoneNotify": {"Name":"ZoneNotify","Docs":"","Fields":[{"Name":"ID","Docs":"","Typewords":["int64"]},{"Name":"Created","Docs":"","Typewords":["timestamp"]},{"Name":"Zone","Docs":"","Typewords":["string"]},{"Name":"Address","Docs":"","Typewords":["string"]},{"Name":"Protocol","Docs":"","Typewords":["string"]}]},
"Credential": {"Name":"Credential","Docs":"","Fields":[{"Name":"ID","Docs":"","Typewords":["int64"]},{"Name":"Created","Docs":"","Typewords":["timestamp"]},{"Name":"Name","Docs":"","Typewords":["string"]},{"Name":"Type","Docs":"","Typewords":["string"]},{"Name":"TSIGSecret","Docs":"","Typewords":["string"]},{"Name":"TLSPublicKey","Docs":"","Typewords":["string"]}]},
"RecordSet": {"Name":"RecordSet","Docs":"","Fields":[{"Name":"Records","Docs":"","Typewords":["[]","Record"]},{"Name":"States","Docs":"","Typewords":["[]","PropagationState"]}]},
"Record": {"Name":"Record","Docs":"","Fields":[{"Name":"ID","Docs":"","Typewords":["int64"]},{"Name":"Zone","Docs":"","Typewords":["string"]},{"Name":"SerialFirst","Docs":"","Typewords":["uint32"]},{"Name":"SerialDeleted","Docs":"","Typewords":["uint32"]},{"Name":"First","Docs":"","Typewords":["timestamp"]},{"Name":"Deleted","Docs":"","Typewords":["nullable","timestamp"]},{"Name":"AbsName","Docs":"","Typewords":["string"]},{"Name":"Type","Docs":"","Typewords":["uint16"]},{"Name":"Class","Docs":"","Typewords":["uint16"]},{"Name":"TTL","Docs":"","Typewords":["uint32"]},{"Name":"DataHex","Docs":"","Typewords":["string"]},{"Name":"Value","Docs":"","Typewords":["string"]},{"Name":"ProviderID","Docs":"","Typewords":["string"]}]},
"PropagationState": {"Name":"PropagationState","Docs":"","Fields":[{"Name":"Start","Docs":"","Typewords":["timestamp"]},{"Name":"End","Docs":"","Typewords":["nullable","timestamp"]},{"Name":"Negative","Docs":"","Typewords":["bool"]},{"Name":"Records","Docs":"","Typewords":["[]","Record"]}]},
"RecordSetChange": {"Name":"RecordSetChange","Docs":"","Fields":[{"Name":"RelName","Docs":"","Typewords":["string"]},{"Name":"TTL","Docs":"","Typewords":["uint32"]},{"Name":"Type","Docs":"","Typewords":["uint16"]},{"Name":"Values","Docs":"","Typewords":["[]","string"]}]},
"KnownProviders": {"Name":"KnownProviders","Docs":"","Fields":[{"Name":"Xalidns","Docs":"","Typewords":["Provider_alidns"]},{"Name":"Xautodns","Docs":"","Typewords":["Provider_autodns"]},{"Name":"Xazure","Docs":"","Typewords":["Provider_azure"]},{"Name":"Xbunny","Docs":"","Typewords":["Provider_bunny"]},{"Name":"Xcivo","Docs":"","Typewords":["Provider_civo"]},{"Name":"Xcloudflare","Docs":"","Typewords":["Provider_cloudflare"]},{"Name":"Xcloudns","Docs":"","Typewords":["Provider_cloudns"]},{"Name":"Xddnss","Docs":"","Typewords":["Provider_ddnss"]},{"Name":"Xdesec","Docs":"","Typewords":["Provider_desec"]},{"Name":"Xdigitalocean","Docs":"","Typewords":["Provider_digitalocean"]},{"Name":"Xdirectadmin","Docs":"","Typewords":["Provider_directadmin"]},{"Name":"Xdnsimple","Docs":"","Typewords":["Provider_dnsimple"]},{"Name":"Xdnsmadeeasy","Docs":"","Typewords":["Provider_dnsmadeeasy"]},{"Name":"Xdnspod","Docs":"","Typewords":["Provider_dnspod"]},{"Name":"Xdnsupdate","Docs":"","Typewords":["Provider_dnsupdate"]},{"Name":"Xdomainnameshop","Docs":"","Typewords":["Provider_domainnameshop"]},{"Name":"Xdreamhost","Docs":"","Typewords":["Provider_dreamhost"]},{"Name":"Xduckdns","Docs":"","Typewords":["Provider_duckdns"]},{"Name":"Xdynu","Docs":"","Typewords":["Provider_dynu"]},{"Name":"Xdynv6","Docs":"","Typewords":["Provider_dynv6"]},{"Name":"Xeasydns","Docs":"","Typewords":["Provider_easydns"]},{"Name":"Xexoscale","Docs":"","Typewords":["Provider_exoscale"]},{"Name":"Xgandi","Docs":"","Typewords":["Provider_gandi"]},{"Name":"Xgcore","Docs":"","Typewords":["Provider_gcore"]},{"Name":"Xglesys","Docs":"","Typewords":["Provider_glesys"]},{"Name":"Xgodaddy","Docs":"","Typewords":["Provider_godaddy"]},{"Name":"Xgoogleclouddns","Docs":"","Typewords":["Provider_googleclouddns"]},{"Name":"Xhe","Docs":"","Typewords":["Provider_he"]},{"Name":"Xhetzner","Docs":"","Typewords":["Provider_hetzner"]},{"Name":"Xhexonet","Docs":"","Typewords":["Provider_hexonet"]},{"Name":"Xhosttech","Docs":"","Typewords":["Provider_hosttech"]},{"Name":"Xhuaweicloud","Docs":"","Typewords":["Provider_huaweicloud"]},{"Name":"Xinfomaniak","Docs":"","Typewords":["Provider_infomaniak"]},{"Name":"Xinwx","Docs":"","Typewords":["Provider_inwx"]},{"Name":"Xionos","Docs":"","Typewords":["Provider_ionos"]},{"Name":"Xkatapult","Docs":"","Typewords":["Provider_katapult"]},{"Name":"Xleaseweb","Docs":"","Typewords":["Provider_leaseweb"]},{"Name":"Xlinode","Docs":"","Typewords":["Provider_linode"]},{"Name":"Xloopia","Docs":"","Typewords":["Provider_loopia"]},{"Name":"Xluadns","Docs":"","Typewords":["Provider_luadns"]},{"Name":"Xmailinabox","Docs":"","Typewords":["Provider_mailinabox"]},{"Name":"Xmetaname","Docs":"","Typewords":["Provider_metaname"]},{"Name":"Xmijnhost","Docs":"","Typewords":["Provider_mijnhost"]},{"Name":"Xmythicbeasts","Docs":"","Typewords":["Provider_mythicbeasts"]},{"Name":"Xnamecheap","Docs":"","Typewords":["Provider_namecheap"]},{"Name":"Xnamedotcom","Docs":"","Typewords":["Provider_namedotcom"]},{"Name":"Xnamesilo","Docs":"","Typewords":["Provider_namesilo"]},{"Name":"Xnanelo","Docs":"","Typewords":["Provider_nanelo"]},{"Name":"Xnetcup","Docs":"","Typewords":["Provider_netcup"]},{"Name":"Xnetlify","Docs":"","Typewords":["Provider_netlify"]},{"Name":"Xnfsn","Docs":"","Typewords":["Provider_nfsn"]},{"Name":"Xnjalla","Docs":"","Typewords":["Provider_njalla"]},{"Name":"Xopenstackdesignate","Docs":"","Typewords":["Provider"]},{"Name":"Xovh","Docs":"","Typewords":["Provider_ovh"]},{"Name":"Xporkbun","Docs":"","Typewords":["Provider_porkbun"]},{"Name":"Xpowerdns","Docs":"","Typewords":["Provider_powerdns"]},{"Name":"Xrfc2136","Docs":"","Typewords":["Provider_rfc2136"]},{"Name":"Xroute53","Docs":"","Typewords":["Provider_route53"]},{"Name":"Xscaleway","Docs":"","Typewords":["Provider_scaleway"]},{"Name":"Xselectel","Docs":"","Typewords":["Provider_selectel"]},{"Name":"Xtencentcloud","Docs":"","Typewords":["Provider_tencentcloud"]},{"Name":"Xtimeweb","Docs":"","Typewords":["Provider_timeweb"]},{"Name":"Xtotaluptime","Docs":"","Typewords":["Provider_totaluptime"]},{"Name":"Xvultr","Docs":"","Typewords":["Provider_vultr"]},{"Name":"Xwestcn","Docs":"","Typewords":["Provider_westcn"]}]},
"Provider_alidns": {"Name":"Provider_alidns","Docs":"","Fields":[{"Name":"access_key_id","Docs":"","Typewords":["string"]},{"Name":"access_key_secret","Docs":"","Typewords":["string"]},{"Name":"region_id","Docs":"","Typewords":["nullable","string"]}]},
"Provider_autodns": {"Name":"Provider_autodns","Docs":"","Fields":[{"Name":"username","Docs":"","Typewords":["string"]},{"Name":"password","Docs":"","Typewords":["string"]},{"Name":"Endpoint","Docs":"","Typewords":["string"]},{"Name":"context","Docs":"","Typewords":["string"]},{"Name":"primary","Docs":"","Typewords":["string"]}]},
"Provider_azure": {"Name":"Provider_azure","Docs":"","Fields":[{"Name":"subscription_id","Docs":"","Typewords":["nullable","string"]},{"Name":"resource_group_name","Docs":"","Typewords":["nullable","string"]},{"Name":"tenant_id","Docs":"","Typewords":["nullable","string"]},{"Name":"client_id","Docs":"","Typewords":["nullable","string"]},{"Name":"client_secret","Docs":"","Typewords":["nullable","string"]}]},
"Provider_bunny": {"Name":"Provider_bunny","Docs":"","Fields":[{"Name":"access_key","Docs":"","Typewords":["string"]},{"Name":"debug","Docs":"","Typewords":["bool"]}]},
"Provider_civo": {"Name":"Provider_civo","Docs":"","Fields":[{"Name":"api_token","Docs":"","Typewords":["nullable","string"]}]},
"Provider_cloudflare": {"Name":"Provider_cloudflare","Docs":"","Fields":[{"Name":"api_token","Docs":"","Typewords":["nullable","string"]},{"Name":"zone_token","Docs":"","Typewords":["nullable","string"]}]},
"Provider_cloudns": {"Name":"Provider_cloudns","Docs":"","Fields":[{"Name":"auth_id","Docs":"","Typewords":["string"]},{"Name":"sub_auth_id","Docs":"","Typewords":["nullable","string"]},{"Name":"auth_password","Docs":"","Typewords":["string"]}]},
"Provider_ddnss": {"Name":"Provider_ddnss","Docs":"","Fields":[{"Name":"api_token","Docs":"","Typewords":["string"]},{"Name":"username","Docs":"","Typewords":["nullable","string"]},{"Name":"password","Docs":"","Typewords":["nullable","string"]}]},
"Provider_desec": {"Name":"Provider_desec","Docs":"","Fields":[{"Name":"token","Docs":"","Typewords":["nullable","string"]}]},
"Provider_digitalocean": {"Name":"Provider_digitalocean","Docs":"","Fields":[{"Name":"auth_token","Docs":"","Typewords":["string"]}]},
"Provider_directadmin": {"Name":"Provider_directadmin","Docs":"","Fields":[{"Name":"host","Docs":"","Typewords":["nullable","string"]},{"Name":"user","Docs":"","Typewords":["nullable","string"]},{"Name":"login_key","Docs":"","Typewords":["nullable","string"]},{"Name":"insecure_requests","Docs":"","Typewords":["nullable","bool"]},{"Name":"debug","Docs":"","Typewords":["nullable","string"]}]},
"Provider_dnsimple": {"Name":"Provider_dnsimple","Docs":"","Fields":[{"Name":"api_access_token","Docs":"","Typewords":["nullable","string"]},{"Name":"account_id","Docs":"","Typewords":["nullable","string"]},{"Name":"api_url","Docs":"","Typewords":["nullable","string"]}]},
"Provider_dnsmadeeasy": {"Name":"Provider_dnsmadeeasy","Docs":"","Fields":[{"Name":"api_key","Docs":"","Typewords":["nullable","string"]},{"Name":"secret_key","Docs":"","Typewords":["nullable","string"]},{"Name":"api_endpoint","Docs":"","Typewords":["nullable","BaseURL"]}]},
"Provider_dnspod": {"Name":"Provider_dnspod","Docs":"","Fields":[{"Name":"auth_token","Docs":"","Typewords":["string"]}]},
"Provider_dnsupdate": {"Name":"Provider_dnsupdate","Docs":"","Fields":[{"Name":"addr","Docs":"","Typewords":["nullable","string"]}]},
"Provider_domainnameshop": {"Name":"Provider_domainnameshop","Docs":"","Fields":[{"Name":"api_token","Docs":"","Typewords":["string"]},{"Name":"api_secret","Docs":"","Typewords":["string"]}]},
"Provider_dreamhost": {"Name":"Provider_dreamhost","Docs":"","Fields":[{"Name":"api_key","Docs":"","Typewords":["nullable","string"]}]},
"Provider_duckdns": {"Name":"Provider_duckdns","Docs":"","Fields":[{"Name":"api_token","Docs":"","Typewords":["nullable","string"]},{"Name":"override_domain","Docs":"","Typewords":["nullable","string"]}]},
"Provider_dynu": {"Name":"Provider_dynu","Docs":"","Fields":[{"Name":"api_token","Docs":"","Typewords":["nullable","string"]},{"Name":"own_domain","Docs":"","Typewords":["nullable","string"]}]},
"Provider_dynv6": {"Name":"Provider_dynv6","Docs":"","Fields":[{"Name":"token","Docs":"","Typewords":["nullable","string"]}]},
"Provider_easydns": {"Name":"Provider_easydns","Docs":"","Fields":[{"Name":"api_token","Docs":"","Typewords":["nullable","string"]},{"Name":"api_key","Docs":"","Typewords":["nullable","string"]},{"Name":"api_url","Docs":"","Typewords":["nullable","string"]}]},
"Provider_exoscale": {"Name":"Provider_exoscale","Docs":"","Fields":[{"Name":"api_key","Docs":"","Typewords":["nullable","string"]},{"Name":"api_secret","Docs":"","Typewords":["nullable","string"]}]},
"Provider_gandi": {"Name":"Provider_gandi","Docs":"","Fields":[{"Name":"bearer_token","Docs":"","Typewords":["nullable","string"]}]},
"Provider_gcore": {"Name":"Provider_gcore","Docs":"","Fields":[{"Name":"api_key","Docs":"","Typewords":["nullable","string"]}]},
"Provider_glesys": {"Name":"Provider_glesys","Docs":"","Fields":[{"Name":"project","Docs":"","Typewords":["nullable","string"]},{"Name":"api_key","Docs":"","Typewords":["nullable","string"]}]},
"Provider_godaddy": {"Name":"Provider_godaddy","Docs":"","Fields":[{"Name":"api_token","Docs":"","Typewords":["nullable","string"]}]},
"Provider_googleclouddns": {"Name":"Provider_googleclouddns","Docs":"","Fields":[{"Name":"gcp_project","Docs":"","Typewords":["nullable","string"]},{"Name":"gcp_application_default","Docs":"","Typewords":["nullable","string"]}]},
"Provider_he": {"Name":"Provider_he","Docs":"","Fields":[{"Name":"api_key","Docs":"","Typewords":["nullable","string"]}]},
"Provider_hetzner": {"Name":"Provider_hetzner","Docs":"","Fields":[{"Name":"auth_api_token","Docs":"","Typewords":["string"]}]},
"Provider_hexonet": {"Name":"Provider_hexonet","Docs":"","Fields":[{"Name":"username","Docs":"","Typewords":["string"]},{"Name":"password","Docs":"","Typewords":["nullable","string"]},{"Name":"debug","Docs":"","Typewords":["nullable","string"]}]},
"Provider_hosttech": {"Name":"Provider_hosttech","Docs":"","Fields":[{"Name":"api_token","Docs":"","Typewords":["nullable","string"]}]},
"Provider_huaweicloud": {"Name":"Provider_huaweicloud","Docs":"","Fields":[{"Name":"access_key_id","Docs":"","Typewords":["nullable","string"]},{"Name":"secret_access_key","Docs":"","Typewords":["nullable","string"]},{"Name":"region_id","Docs":"","Typewords":["nullable","string"]}]},
"Provider_infomaniak": {"Name":"Provider_infomaniak","Docs":"","Fields":[{"Name":"api_token","Docs":"","Typewords":["nullable","string"]}]},
"Provider_inwx": {"Name":"Provider_inwx","Docs":"","Fields":[{"Name":"username","Docs":"","Typewords":["nullable","string"]},{"Name":"password","Docs":"","Typewords":["nullable","string"]},{"Name":"shared_secret","Docs":"","Typewords":["nullable","string"]},{"Name":"endpoint_url","Docs":"","Typewords":["nullable","string"]}]},
"Provider_ionos": {"Name":"Provider_ionos","Docs":"","Fields":[{"Name":"auth_api_token","Docs":"","Typewords":["string"]}]},
"Provider_katapult": {"Name":"Provider_katapult","Docs":"","Fields":[{"Name":"api_token","Docs":"","Typewords":["nullable","string"]}]},
"Provider_leaseweb": {"Name":"Provider_leaseweb","Docs":"","Fields":[{"Name":"api_token","Docs":"","Typewords":["nullable","string"]}]},
"Provider_linode": {"Name":"Provider_linode","Docs":"","Fields":[{"Name":"api_token","Docs":"","Typewords":["nullable","string"]},{"Name":"api_url","Docs":"","Typewords":["nullable","string"]},{"Name":"api_version","Docs":"","Typewords":["nullable","string"]}]},
"Provider_loopia": {"Name":"Provider_loopia","Docs":"","Fields":[{"Name":"username","Docs":"","Typewords":["nullable","string"]},{"Name":"password","Docs":"","Typewords":["nullable","string"]},{"Name":"customer","Docs":"","Typewords":["nullable","string"]}]},
"Provider_luadns": {"Name":"Provider_luadns","Docs":"","Fields":[{"Name":"email","Docs":"","Typewords":["nullable","string"]},{"Name":"api_key","Docs":"","Typewords":["nullable","string"]}]},
"Provider_mailinabox": {"Name":"Provider_mailinabox","Docs":"","Fields":[{"Name":"api_url","Docs":"","Typewords":["nullable","string"]},{"Name":"email_address","Docs":"","Typewords":["nullable","string"]},{"Name":"password","Docs":"","Typewords":["nullable","string"]}]},
"Provider_metaname": {"Name":"Provider_metaname","Docs":"","Fields":[{"Name":"api_key","Docs":"","Typewords":["nullable","string"]},{"Name":"account_reference","Docs":"","Typewords":["nullable","string"]},{"Name":"endpoint","Docs":"","Typewords":["nullable","string"]}]},
"Provider_mijnhost": {"Name":"Provider_mijnhost","Docs":"","Fields":[{"Name":"api_token","Docs":"","Typewords":["nullable","string"]}]},
"Provider_mythicbeasts": {"Name":"Provider_mythicbeasts","Docs":"","Fields":[{"Name":"key_id","Docs":"","Typewords":["nullable","string"]},{"Name":"secret","Docs":"","Typewords":["nullable","string"]}]},
"Provider_namecheap": {"Name":"Provider_namecheap","Docs":"","Fields":[{"Name":"api_key","Docs":"","Typewords":["nullable","string"]},{"Name":"user","Docs":"","Typewords":["nullable","string"]},{"Name":"api_endpoint","Docs":"","Typewords":["nullable","string"]},{"Name":"client_ip","Docs":"","Typewords":["nullable","string"]}]},
"Provider_namedotcom": {"Name":"Provider_namedotcom","Docs":"","Fields":[{"Name":"api_token","Docs":"","Typewords":["nullable","string"]},{"Name":"user","Docs":"","Typewords":["nullable","string"]},{"Name":"server","Docs":"","Typewords":["nullable","string"]}]},
"Provider_namesilo": {"Name":"Provider_namesilo","Docs":"","Fields":[{"Name":"api_token","Docs":"","Typewords":["nullable","string"]}]},
"Provider_nanelo": {"Name":"Provider_nanelo","Docs":"","Fields":[{"Name":"api_token","Docs":"","Typewords":["nullable","string"]}]},
"Provider_netcup": {"Name":"Provider_netcup","Docs":"","Fields":[{"Name":"customer_number","Docs":"","Typewords":["string"]},{"Name":"api_key","Docs":"","Typewords":["string"]},{"Name":"api_password","Docs":"","Typewords":["string"]}]},
"Provider_netlify": {"Name":"Provider_netlify","Docs":"","Fields":[{"Name":"personal_access_token","Docs":"","Typewords":["nullable","string"]}]},
"Provider_nfsn": {"Name":"Provider_nfsn","Docs":"","Fields":[{"Name":"login","Docs":"","Typewords":["nullable","string"]},{"Name":"api_key","Docs":"","Typewords":["nullable","string"]}]},
"Provider_njalla": {"Name":"Provider_njalla","Docs":"","Fields":[{"Name":"api_token","Docs":"","Typewords":["nullable","string"]}]},
"Provider": {"Name":"Provider","Docs":"","Fields":[{"Name":"auth_open_stack","Docs":"","Typewords":["AuthOpenStack"]}]},
"AuthOpenStack": {"Name":"AuthOpenStack","Docs":"","Fields":[{"Name":"region_name","Docs":"","Typewords":["string"]},{"Name":"tenant_id","Docs":"","Typewords":["string"]},{"Name":"identity_api_version","Docs":"","Typewords":["string"]},{"Name":"password","Docs":"","Typewords":["string"]},{"Name":"auth_url","Docs":"","Typewords":["string"]},{"Name":"username","Docs":"","Typewords":["string"]},{"Name":"tenant_name","Docs":"","Typewords":["string"]},{"Name":"endpoint_type","Docs":"","Typewords":["string"]}]},
"Provider_ovh": {"Name":"Provider_ovh","Docs":"","Fields":[{"Name":"endpoint","Docs":"","Typewords":["nullable","string"]},{"Name":"application_key","Docs":"","Typewords":["nullable","string"]},{"Name":"application_secret","Docs":"","Typewords":["nullable","string"]},{"Name":"consumer_key","Docs":"","Typewords":["nullable","string"]}]},
"Provider_porkbun": {"Name":"Provider_porkbun","Docs":"","Fields":[{"Name":"api_key","Docs":"","Typewords":["nullable","string"]},{"Name":"api_secret_key","Docs":"","Typewords":["nullable","string"]}]},
"Provider_powerdns": {"Name":"Provider_powerdns","Docs":"","Fields":[{"Name":"server_url","Docs":"","Typewords":["string"]},{"Name":"server_id","Docs":"","Typewords":["nullable","string"]},{"Name":"api_token","Docs":"","Typewords":["nullable","string"]},{"Name":"debug","Docs":"","Typewords":["nullable","string"]}]},
"Provider_rfc2136": {"Name":"Provider_rfc2136","Docs":"","Fields":[{"Name":"key_name","Docs":"","Typewords":["nullable","string"]},{"Name":"key_alg","Docs":"","Typewords":["nullable","string"]},{"Name":"key","Docs":"","Typewords":["nullable","string"]},{"Name":"server","Docs":"","Typewords":["nullable","string"]}]},
"Provider_route53": {"Name":"Provider_route53","Docs":"","Fields":[{"Name":"region","Docs":"","Typewords":["nullable","string"]},{"Name":"aws_profile","Docs":"","Typewords":["nullable","string"]},{"Name":"profile","Docs":"","Typewords":["nullable","string"]},{"Name":"access_key_id","Docs":"","Typewords":["nullable","string"]},{"Name":"secret_access_key","Docs":"","Typewords":["nullable","string"]},{"Name":"token","Docs":"","Typewords":["nullable","string"]},{"Name":"session_token","Docs":"","Typewords":["nullable","string"]},{"Name":"max_retries","Docs":"","Typewords":["nullable","int32"]},{"Name":"max_wait_dur","Docs":"","Typewords":["nullable","int64"]},{"Name":"wait_for_propagation","Docs":"","Typewords":["nullable","bool"]},{"Name":"hosted_zone_id","Docs":"","Typewords":["nullable","string"]}]},
"Provider_scaleway": {"Name":"Provider_scaleway","Docs":"","Fields":[{"Name":"secret_key","Docs":"","Typewords":["nullable","string"]},{"Name":"organization_id","Docs":"","Typewords":["nullable","string"]}]},
"Provider_selectel": {"Name":"Provider_selectel","Docs":"","Fields":[{"Name":"user","Docs":"","Typewords":["nullable","string"]},{"Name":"password","Docs":"","Typewords":["nullable","string"]},{"Name":"account_id","Docs":"","Typewords":["nullable","string"]},{"Name":"project_name","Docs":"","Typewords":["nullable","string"]},{"Name":"KeystoneToken","Docs":"","Typewords":["string"]}]},
"Provider_tencentcloud": {"Name":"Provider_tencentcloud","Docs":"","Fields":[{"Name":"SecretId","Docs":"","Typewords":["string"]},{"Name":"SecretKey","Docs":"","Typewords":["string"]}]},
"Provider_timeweb": {"Name":"Provider_timeweb","Docs":"","Fields":[{"Name":"ApiURL","Docs":"","Typewords":["string"]},{"Name":"ApiToken","Docs":"","Typewords":["string"]}]},
"Provider_totaluptime": {"Name":"Provider_totaluptime","Docs":"","Fields":[{"Name":"username","Docs":"","Typewords":["nullable","string"]},{"Name":"password","Docs":"","Typewords":["nullable","string"]}]},
"Provider_vultr": {"Name":"Provider_vultr","Docs":"","Fields":[{"Name":"api_token","Docs":"","Typewords":["nullable","string"]}]},
"Provider_westcn": {"Name":"Provider_westcn","Docs":"","Fields":[{"Name":"username","Docs":"","Typewords":["nullable","string"]},{"Name":"api_password","Docs":"","Typewords":["nullable","string"]}]},
"sherpadocSection": {"Name":"sherpadocSection","Docs":"","Fields":[{"Name":"Name","Docs":"","Typewords":["string"]},{"Name":"Docs","Docs":"","Typewords":["string"]},{"Name":"Functions","Docs":"","Typewords":["[]","nullable","sherpadocFunction"]},{"Name":"Sections","Docs":"","Typewords":["[]","nullable","sherpadocSection"]},{"Name":"Structs","Docs":"","Typewords":["[]","sherpadocStruct"]},{"Name":"Ints","Docs":"","Typewords":["[]","sherpadocInts"]},{"Name":"Strings","Docs":"","Typewords":["[]","sherpadocStrings"]},{"Name":"Version","Docs":"","Typewords":["nullable","string"]},{"Name":"SherpaVersion","Docs":"","Typewords":["int32"]},{"Name":"SherpadocVersion","Docs":"","Typewords":["nullable","int32"]}]},
"sherpadocFunction": {"Name":"sherpadocFunction","Docs":"","Fields":[{"Name":"Name","Docs":"","Typewords":["string"]},{"Name":"Docs","Docs":"","Typewords":["string"]},{"Name":"Params","Docs":"","Typewords":["[]","sherpadocArg"]},{"Name":"Returns","Docs":"","Typewords":["[]","sherpadocArg"]}]},
"sherpadocArg": {"Name":"sherpadocArg","Docs":"","Fields":[{"Name":"Name","Docs":"","Typewords":["string"]},{"Name":"Typewords","Docs":"","Typewords":["[]","string"]}]},
"sherpadocStruct": {"Name":"sherpadocStruct","Docs":"","Fields":[{"Name":"Name","Docs":"","Typewords":["string"]},{"Name":"Docs","Docs":"","Typewords":["string"]},{"Name":"Fields","Docs":"","Typewords":["[]","sherpadocField"]}]},
"sherpadocField": {"Name":"sherpadocField","Docs":"","Fields":[{"Name":"Name","Docs":"","Typewords":["string"]},{"Name":"Docs","Docs":"","Typewords":["string"]},{"Name":"Typewords","Docs":"","Typewords":["[]","string"]}]},
"sherpadocInts": {"Name":"sherpadocInts","Docs":"","Fields":[{"Name":"Name","Docs":"","Typewords":["string"]},{"Name":"Docs","Docs":"","Typewords":["string"]},{"Name":"Values","Docs":"","Typewords":["[]","IntValue"]}]},
"IntValue": {"Name":"IntValue","Docs":"","Fields":[{"Name":"Name","Docs":"","Typewords":["string"]},{"Name":"Value","Docs":"","Typewords":["int64"]},{"Name":"Docs","Docs":"","Typewords":["string"]}]},
"sherpadocStrings": {"Name":"sherpadocStrings","Docs":"","Fields":[{"Name":"Name","Docs":"","Typewords":["string"]},{"Name":"Docs","Docs":"","Typewords":["string"]},{"Name":"Values","Docs":"","Typewords":["[]","StringValue"]}]},
"StringValue": {"Name":"StringValue","Docs":"","Fields":[{"Name":"Name","Docs":"","Typewords":["string"]},{"Name":"Value","Docs":"","Typewords":["string"]},{"Name":"Docs","Docs":"","Typewords":["string"]}]},
"BaseURL": {"Name":"BaseURL","Docs":"","Values":[{"Name":"Sandbox","Value":"https://api.sandbox.dnsmadeeasy.com/V2.0/","Docs":""},{"Name":"Prod","Value":"https://api.dnsmadeeasy.com/V2.0/","Docs":""}]},
}
export const parser = {
Zone: (v: any) => parse("Zone", v) as Zone,
ProviderConfig: (v: any) => parse("ProviderConfig", v) as ProviderConfig,
ZoneNotify: (v: any) => parse("ZoneNotify", v) as ZoneNotify,
Credential: (v: any) => parse("Credential", v) as Credential,
RecordSet: (v: any) => parse("RecordSet", v) as RecordSet,
Record: (v: any) => parse("Record", v) as Record,
PropagationState: (v: any) => parse("PropagationState", v) as PropagationState,
RecordSetChange: (v: any) => parse("RecordSetChange", v) as RecordSetChange,
KnownProviders: (v: any) => parse("KnownProviders", v) as KnownProviders,
Provider_alidns: (v: any) => parse("Provider_alidns", v) as Provider_alidns,
Provider_autodns: (v: any) => parse("Provider_autodns", v) as Provider_autodns,
Provider_azure: (v: any) => parse("Provider_azure", v) as Provider_azure,
Provider_bunny: (v: any) => parse("Provider_bunny", v) as Provider_bunny,
Provider_civo: (v: any) => parse("Provider_civo", v) as Provider_civo,
Provider_cloudflare: (v: any) => parse("Provider_cloudflare", v) as Provider_cloudflare,
Provider_cloudns: (v: any) => parse("Provider_cloudns", v) as Provider_cloudns,
Provider_ddnss: (v: any) => parse("Provider_ddnss", v) as Provider_ddnss,
Provider_desec: (v: any) => parse("Provider_desec", v) as Provider_desec,
Provider_digitalocean: (v: any) => parse("Provider_digitalocean", v) as Provider_digitalocean,
Provider_directadmin: (v: any) => parse("Provider_directadmin", v) as Provider_directadmin,
Provider_dnsimple: (v: any) => parse("Provider_dnsimple", v) as Provider_dnsimple,
Provider_dnsmadeeasy: (v: any) => parse("Provider_dnsmadeeasy", v) as Provider_dnsmadeeasy,
Provider_dnspod: (v: any) => parse("Provider_dnspod", v) as Provider_dnspod,
Provider_dnsupdate: (v: any) => parse("Provider_dnsupdate", v) as Provider_dnsupdate,
Provider_domainnameshop: (v: any) => parse("Provider_domainnameshop", v) as Provider_domainnameshop,
Provider_dreamhost: (v: any) => parse("Provider_dreamhost", v) as Provider_dreamhost,
Provider_duckdns: (v: any) => parse("Provider_duckdns", v) as Provider_duckdns,
Provider_dynu: (v: any) => parse("Provider_dynu", v) as Provider_dynu,
Provider_dynv6: (v: any) => parse("Provider_dynv6", v) as Provider_dynv6,
Provider_easydns: (v: any) => parse("Provider_easydns", v) as Provider_easydns,
Provider_exoscale: (v: any) => parse("Provider_exoscale", v) as Provider_exoscale,
Provider_gandi: (v: any) => parse("Provider_gandi", v) as Provider_gandi,
Provider_gcore: (v: any) => parse("Provider_gcore", v) as Provider_gcore,
Provider_glesys: (v: any) => parse("Provider_glesys", v) as Provider_glesys,
Provider_godaddy: (v: any) => parse("Provider_godaddy", v) as Provider_godaddy,
Provider_googleclouddns: (v: any) => parse("Provider_googleclouddns", v) as Provider_googleclouddns,
Provider_he: (v: any) => parse("Provider_he", v) as Provider_he,
Provider_hetzner: (v: any) => parse("Provider_hetzner", v) as Provider_hetzner,
Provider_hexonet: (v: any) => parse("Provider_hexonet", v) as Provider_hexonet,
Provider_hosttech: (v: any) => parse("Provider_hosttech", v) as Provider_hosttech,
Provider_huaweicloud: (v: any) => parse("Provider_huaweicloud", v) as Provider_huaweicloud,
Provider_infomaniak: (v: any) => parse("Provider_infomaniak", v) as Provider_infomaniak,
Provider_inwx: (v: any) => parse("Provider_inwx", v) as Provider_inwx,
Provider_ionos: (v: any) => parse("Provider_ionos", v) as Provider_ionos,
Provider_katapult: (v: any) => parse("Provider_katapult", v) as Provider_katapult,
Provider_leaseweb: (v: any) => parse("Provider_leaseweb", v) as Provider_leaseweb,
Provider_linode: (v: any) => parse("Provider_linode", v) as Provider_linode,
Provider_loopia: (v: any) => parse("Provider_loopia", v) as Provider_loopia,
Provider_luadns: (v: any) => parse("Provider_luadns", v) as Provider_luadns,
Provider_mailinabox: (v: any) => parse("Provider_mailinabox", v) as Provider_mailinabox,
Provider_metaname: (v: any) => parse("Provider_metaname", v) as Provider_metaname,
Provider_mijnhost: (v: any) => parse("Provider_mijnhost", v) as Provider_mijnhost,
Provider_mythicbeasts: (v: any) => parse("Provider_mythicbeasts", v) as Provider_mythicbeasts,
Provider_namecheap: (v: any) => parse("Provider_namecheap", v) as Provider_namecheap,
Provider_namedotcom: (v: any) => parse("Provider_namedotcom", v) as Provider_namedotcom,
Provider_namesilo: (v: any) => parse("Provider_namesilo", v) as Provider_namesilo,
Provider_nanelo: (v: any) => parse("Provider_nanelo", v) as Provider_nanelo,
Provider_netcup: (v: any) => parse("Provider_netcup", v) as Provider_netcup,
Provider_netlify: (v: any) => parse("Provider_netlify", v) as Provider_netlify,
Provider_nfsn: (v: any) => parse("Provider_nfsn", v) as Provider_nfsn,
Provider_njalla: (v: any) => parse("Provider_njalla", v) as Provider_njalla,
Provider: (v: any) => parse("Provider", v) as Provider,
AuthOpenStack: (v: any) => parse("AuthOpenStack", v) as AuthOpenStack,
Provider_ovh: (v: any) => parse("Provider_ovh", v) as Provider_ovh,
Provider_porkbun: (v: any) => parse("Provider_porkbun", v) as Provider_porkbun,
Provider_powerdns: (v: any) => parse("Provider_powerdns", v) as Provider_powerdns,
Provider_rfc2136: (v: any) => parse("Provider_rfc2136", v) as Provider_rfc2136,
Provider_route53: (v: any) => parse("Provider_route53", v) as Provider_route53,
Provider_scaleway: (v: any) => parse("Provider_scaleway", v) as Provider_scaleway,
Provider_selectel: (v: any) => parse("Provider_selectel", v) as Provider_selectel,
Provider_tencentcloud: (v: any) => parse("Provider_tencentcloud", v) as Provider_tencentcloud,
Provider_timeweb: (v: any) => parse("Provider_timeweb", v) as Provider_timeweb,
Provider_totaluptime: (v: any) => parse("Provider_totaluptime", v) as Provider_totaluptime,
Provider_vultr: (v: any) => parse("Provider_vultr", v) as Provider_vultr,
Provider_westcn: (v: any) => parse("Provider_westcn", v) as Provider_westcn,
sherpadocSection: (v: any) => parse("sherpadocSection", v) as sherpadocSection,
sherpadocFunction: (v: any) => parse("sherpadocFunction", v) as sherpadocFunction,
sherpadocArg: (v: any) => parse("sherpadocArg", v) as sherpadocArg,
sherpadocStruct: (v: any) => parse("sherpadocStruct", v) as sherpadocStruct,
sherpadocField: (v: any) => parse("sherpadocField", v) as sherpadocField,
sherpadocInts: (v: any) => parse("sherpadocInts", v) as sherpadocInts,
IntValue: (v: any) => parse("IntValue", v) as IntValue,
sherpadocStrings: (v: any) => parse("sherpadocStrings", v) as sherpadocStrings,
StringValue: (v: any) => parse("StringValue", v) as StringValue,
BaseURL: (v: any) => parse("BaseURL", v) as BaseURL,
}
// API is the webapi used by the admin frontend.
let defaultOptions: ClientOptions = {slicesNullable: true, mapsNullable: true, nullableOptional: true}
export class Client {
private baseURL: string
public authState: AuthState
public options: ClientOptions
constructor() {
this.authState = {}
this.options = {...defaultOptions}
this.baseURL = this.options.baseURL || defaultBaseURL
}
withAuthToken(token: string): Client {
const c = new Client()
c.authState.token = token
c.options = this.options
return c
}
withOptions(options: ClientOptions): Client {
const c = new Client()
c.authState = this.authState
c.options = { ...this.options, ...options }
return c
}
// Zones returns all zones.
async Zones(): Promise<Zone[] | null> {
const fn: string = "Zones"
const paramTypes: string[][] = []
const returnTypes: string[][] = [["[]","Zone"]]
const params: any[] = []
return await _sherpaCall(this.baseURL, this.authState, { ...this.options }, paramTypes, returnTypes, fn, params) as Zone[] | null
}
// Zone returns details about a single zone, the provider config, dns notify
// destinations, credentials with access to the zone, and record sets. The returned
// record sets includes those no long active (i.e. deleted). The
// history/propagation state fo the record sets only includes those that may still
// be in caches. Use ZoneRecordSetHistory for the full history for a single record
// set.
async Zone(zone: string): Promise<[Zone, ProviderConfig, ZoneNotify[] | null, Credential[] | null, RecordSet[] | null]> {
const fn: string = "Zone"
const paramTypes: string[][] = [["string"]]
const returnTypes: string[][] = [["Zone"],["ProviderConfig"],["[]","ZoneNotify"],["[]","Credential"],["[]","RecordSet"]]
const params: any[] = [zone]
return await _sherpaCall(this.baseURL, this.authState, { ...this.options }, paramTypes, returnTypes, fn, params) as [Zone, ProviderConfig, ZoneNotify[] | null, Credential[] | null, RecordSet[] | null]
}
// ZoneRecords returns all records for a zone, including historic records, without
// grouping them into record sets.
async ZoneRecords(zone: string): Promise<Record[] | null> {
const fn: string = "ZoneRecords"
const paramTypes: string[][] = [["string"]]
const returnTypes: string[][] = [["[]","Record"]]
const params: any[] = [zone]
return await _sherpaCall(this.baseURL, this.authState, { ...this.options }, paramTypes, returnTypes, fn, params) as Record[] | null
}
// ZoneRefresh starts a sync of the records from the provider into the local
// database, sending dns notify if needed. ZoneRefresh returns all records
// (included deleted) from after the synchronization.
async ZoneRefresh(zone: string): Promise<[Zone, RecordSet[] | null]> {
const fn: string = "ZoneRefresh"
const paramTypes: string[][] = [["string"]]
const returnTypes: string[][] = [["Zone"],["[]","RecordSet"]]
const params: any[] = [zone]
return await _sherpaCall(this.baseURL, this.authState, { ...this.options }, paramTypes, returnTypes, fn, params) as [Zone, RecordSet[] | null]
}
// ZonePurgeHistory removes historic records from the database, those marked "deleted".
async ZonePurgeHistory(zone: string): Promise<[Zone, RecordSet[] | null]> {
const fn: string = "ZonePurgeHistory"
const paramTypes: string[][] = [["string"]]
const returnTypes: string[][] = [["Zone"],["[]","RecordSet"]]
const params: any[] = [zone]
return await _sherpaCall(this.baseURL, this.authState, { ...this.options }, paramTypes, returnTypes, fn, params) as [Zone, RecordSet[] | null]
}
// ZoneAdd adds a new zone to the database. A TSIG credential is created
// automatically. Records are fetched returning the new zone, in the background.
//
// If pc.ProviderName is non-empty, a new ProviderConfig is added.
async ZoneAdd(z: Zone, notifies: ZoneNotify[] | null): Promise<Zone> {
const fn: string = "ZoneAdd"
const paramTypes: string[][] = [["Zone"],["[]","ZoneNotify"]]
const returnTypes: string[][] = [["Zone"]]
const params: any[] = [z, notifies]
return await _sherpaCall(this.baseURL, this.authState, { ...this.options }, paramTypes, returnTypes, fn, params) as Zone
}
// ZoneDelete removes a zone and all its records, credentials and dns notify addresses, from the database.
async ZoneDelete(zone: string): Promise<void> {
const fn: string = "ZoneDelete"
const paramTypes: string[][] = [["string"]]
const returnTypes: string[][] = []
const params: any[] = [zone]
return await _sherpaCall(this.baseURL, this.authState, { ...this.options }, paramTypes, returnTypes, fn, params) as void
}
// ZoneUpdate updates the provider config and refresh & sync interval for a zone.
async ZoneUpdate(z: Zone): Promise<Zone> {
const fn: string = "ZoneUpdate"
const paramTypes: string[][] = [["Zone"]]
const returnTypes: string[][] = [["Zone"]]
const params: any[] = [z]
return await _sherpaCall(this.baseURL, this.authState, { ...this.options }, paramTypes, returnTypes, fn, params) as Zone
}
// ZoneNotify send a DNS notify message to an address.
async ZoneNotify(zoneNotifyID: number): Promise<void> {
const fn: string = "ZoneNotify"
const paramTypes: string[][] = [["int64"]]
const returnTypes: string[][] = []
const params: any[] = [zoneNotifyID]
return await _sherpaCall(this.baseURL, this.authState, { ...this.options }, paramTypes, returnTypes, fn, params) as void
}
// ZoneNotifyAdd adds a new DNS NOTIFY destination to a zone.
async ZoneNotifyAdd(zn: ZoneNotify): Promise<ZoneNotify> {
const fn: string = "ZoneNotifyAdd"
const paramTypes: string[][] = [["ZoneNotify"]]
const returnTypes: string[][] = [["ZoneNotify"]]
const params: any[] = [zn]
return await _sherpaCall(this.baseURL, this.authState, { ...this.options }, paramTypes, returnTypes, fn, params) as ZoneNotify
}
// ZoneNotifyDelete removes a DNS NOTIFY destination from a zone.
async ZoneNotifyDelete(zoneNotifyID: number): Promise<void> {
const fn: string = "ZoneNotifyDelete"
const paramTypes: string[][] = [["int64"]]
const returnTypes: string[][] = []
const params: any[] = [zoneNotifyID]
return await _sherpaCall(this.baseURL, this.authState, { ...this.options }, paramTypes, returnTypes, fn, params) as void
}
// ZoneCredentialAdd adds a new TSIG or TLS public key credential to a zone.
async ZoneCredentialAdd(zone: string, c: Credential): Promise<Credential> {
const fn: string = "ZoneCredentialAdd"
const paramTypes: string[][] = [["string"],["Credential"]]
const returnTypes: string[][] = [["Credential"]]
const params: any[] = [zone, c]
return await _sherpaCall(this.baseURL, this.authState, { ...this.options }, paramTypes, returnTypes, fn, params) as Credential
}
// ZoneCredentialDelete removes a TSIG/TLS public key credential from a zone.
async ZoneCredentialDelete(credentialID: number): Promise<void> {
const fn: string = "ZoneCredentialDelete"