pulumi-dnsimple 3.5.0a1710156168__py3-none-any.whl → 4.3.0a1736849266__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of pulumi-dnsimple might be problematic. Click here for more details.

@@ -0,0 +1,810 @@
1
+ # coding=utf-8
2
+ # *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
3
+ # *** Do not edit by hand unless you're certain you know what you are doing! ***
4
+
5
+ import copy
6
+ import warnings
7
+ import sys
8
+ import pulumi
9
+ import pulumi.runtime
10
+ from typing import Any, Mapping, Optional, Sequence, Union, overload
11
+ if sys.version_info >= (3, 11):
12
+ from typing import NotRequired, TypedDict, TypeAlias
13
+ else:
14
+ from typing_extensions import NotRequired, TypedDict, TypeAlias
15
+ from . import _utilities
16
+ from . import outputs
17
+ from ._inputs import *
18
+
19
+ __all__ = ['RegisteredDomainArgs', 'RegisteredDomain']
20
+
21
+ @pulumi.input_type
22
+ class RegisteredDomainArgs:
23
+ def __init__(__self__, *,
24
+ contact_id: pulumi.Input[int],
25
+ name: pulumi.Input[str],
26
+ auto_renew_enabled: Optional[pulumi.Input[bool]] = None,
27
+ dnssec_enabled: Optional[pulumi.Input[bool]] = None,
28
+ extended_attributes: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
29
+ premium_price: Optional[pulumi.Input[str]] = None,
30
+ timeouts: Optional[pulumi.Input['RegisteredDomainTimeoutsArgs']] = None,
31
+ transfer_lock_enabled: Optional[pulumi.Input[bool]] = None,
32
+ whois_privacy_enabled: Optional[pulumi.Input[bool]] = None):
33
+ """
34
+ The set of arguments for constructing a RegisteredDomain resource.
35
+ :param pulumi.Input[int] contact_id: The ID of the contact to be used for the domain registration. The contact ID can be changed after the domain has been registered. The change will result in a new registrant change this may result in a [60-day lock](https://support.dnsimple.com/articles/icann-60-day-lock-registrant-change/).
36
+ :param pulumi.Input[str] name: The domain name to be registered
37
+ :param pulumi.Input[bool] auto_renew_enabled: Whether the domain should be set to auto-renew (default: `false`)
38
+ :param pulumi.Input[bool] dnssec_enabled: Whether the domain should have DNSSEC enabled (default: `false`)
39
+ :param pulumi.Input[Mapping[str, pulumi.Input[str]]] extended_attributes: A map of extended attributes to be set for the domain registration. To see if there are any required extended attributes for any TLD use our [Lists the TLD Extended Attributes API](https://developer.dnsimple.com/v2/tlds/#getTldExtendedAttributes). The values provided in the `extended_attributes` will also be sent when a registrant change is initiated as part of changing the `contact_id`.
40
+ :param pulumi.Input[str] premium_price: The premium price for the domain registration. This is only required if the domain is a premium domain. You can use our [Check domain API](https://developer.dnsimple.com/v2/registrar/#checkDomain) to check if a domain is premium. And [Retrieve domain prices API](https://developer.dnsimple.com/v2/registrar/#getDomainPrices) to retrieve the premium price for a domain.
41
+ :param pulumi.Input['RegisteredDomainTimeoutsArgs'] timeouts: (see below for nested schema)
42
+
43
+ # Attributes Reference
44
+ :param pulumi.Input[bool] transfer_lock_enabled: Whether the domain transfer lock protection is enabled (default: `true`)
45
+ :param pulumi.Input[bool] whois_privacy_enabled: Whether the domain should have WhoIs privacy enabled (default: `false`)
46
+ """
47
+ pulumi.set(__self__, "contact_id", contact_id)
48
+ pulumi.set(__self__, "name", name)
49
+ if auto_renew_enabled is not None:
50
+ pulumi.set(__self__, "auto_renew_enabled", auto_renew_enabled)
51
+ if dnssec_enabled is not None:
52
+ pulumi.set(__self__, "dnssec_enabled", dnssec_enabled)
53
+ if extended_attributes is not None:
54
+ pulumi.set(__self__, "extended_attributes", extended_attributes)
55
+ if premium_price is not None:
56
+ pulumi.set(__self__, "premium_price", premium_price)
57
+ if timeouts is not None:
58
+ pulumi.set(__self__, "timeouts", timeouts)
59
+ if transfer_lock_enabled is not None:
60
+ pulumi.set(__self__, "transfer_lock_enabled", transfer_lock_enabled)
61
+ if whois_privacy_enabled is not None:
62
+ pulumi.set(__self__, "whois_privacy_enabled", whois_privacy_enabled)
63
+
64
+ @property
65
+ @pulumi.getter(name="contactId")
66
+ def contact_id(self) -> pulumi.Input[int]:
67
+ """
68
+ The ID of the contact to be used for the domain registration. The contact ID can be changed after the domain has been registered. The change will result in a new registrant change this may result in a [60-day lock](https://support.dnsimple.com/articles/icann-60-day-lock-registrant-change/).
69
+ """
70
+ return pulumi.get(self, "contact_id")
71
+
72
+ @contact_id.setter
73
+ def contact_id(self, value: pulumi.Input[int]):
74
+ pulumi.set(self, "contact_id", value)
75
+
76
+ @property
77
+ @pulumi.getter
78
+ def name(self) -> pulumi.Input[str]:
79
+ """
80
+ The domain name to be registered
81
+ """
82
+ return pulumi.get(self, "name")
83
+
84
+ @name.setter
85
+ def name(self, value: pulumi.Input[str]):
86
+ pulumi.set(self, "name", value)
87
+
88
+ @property
89
+ @pulumi.getter(name="autoRenewEnabled")
90
+ def auto_renew_enabled(self) -> Optional[pulumi.Input[bool]]:
91
+ """
92
+ Whether the domain should be set to auto-renew (default: `false`)
93
+ """
94
+ return pulumi.get(self, "auto_renew_enabled")
95
+
96
+ @auto_renew_enabled.setter
97
+ def auto_renew_enabled(self, value: Optional[pulumi.Input[bool]]):
98
+ pulumi.set(self, "auto_renew_enabled", value)
99
+
100
+ @property
101
+ @pulumi.getter(name="dnssecEnabled")
102
+ def dnssec_enabled(self) -> Optional[pulumi.Input[bool]]:
103
+ """
104
+ Whether the domain should have DNSSEC enabled (default: `false`)
105
+ """
106
+ return pulumi.get(self, "dnssec_enabled")
107
+
108
+ @dnssec_enabled.setter
109
+ def dnssec_enabled(self, value: Optional[pulumi.Input[bool]]):
110
+ pulumi.set(self, "dnssec_enabled", value)
111
+
112
+ @property
113
+ @pulumi.getter(name="extendedAttributes")
114
+ def extended_attributes(self) -> Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]]:
115
+ """
116
+ A map of extended attributes to be set for the domain registration. To see if there are any required extended attributes for any TLD use our [Lists the TLD Extended Attributes API](https://developer.dnsimple.com/v2/tlds/#getTldExtendedAttributes). The values provided in the `extended_attributes` will also be sent when a registrant change is initiated as part of changing the `contact_id`.
117
+ """
118
+ return pulumi.get(self, "extended_attributes")
119
+
120
+ @extended_attributes.setter
121
+ def extended_attributes(self, value: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]]):
122
+ pulumi.set(self, "extended_attributes", value)
123
+
124
+ @property
125
+ @pulumi.getter(name="premiumPrice")
126
+ def premium_price(self) -> Optional[pulumi.Input[str]]:
127
+ """
128
+ The premium price for the domain registration. This is only required if the domain is a premium domain. You can use our [Check domain API](https://developer.dnsimple.com/v2/registrar/#checkDomain) to check if a domain is premium. And [Retrieve domain prices API](https://developer.dnsimple.com/v2/registrar/#getDomainPrices) to retrieve the premium price for a domain.
129
+ """
130
+ return pulumi.get(self, "premium_price")
131
+
132
+ @premium_price.setter
133
+ def premium_price(self, value: Optional[pulumi.Input[str]]):
134
+ pulumi.set(self, "premium_price", value)
135
+
136
+ @property
137
+ @pulumi.getter
138
+ def timeouts(self) -> Optional[pulumi.Input['RegisteredDomainTimeoutsArgs']]:
139
+ """
140
+ (see below for nested schema)
141
+
142
+ # Attributes Reference
143
+ """
144
+ return pulumi.get(self, "timeouts")
145
+
146
+ @timeouts.setter
147
+ def timeouts(self, value: Optional[pulumi.Input['RegisteredDomainTimeoutsArgs']]):
148
+ pulumi.set(self, "timeouts", value)
149
+
150
+ @property
151
+ @pulumi.getter(name="transferLockEnabled")
152
+ def transfer_lock_enabled(self) -> Optional[pulumi.Input[bool]]:
153
+ """
154
+ Whether the domain transfer lock protection is enabled (default: `true`)
155
+ """
156
+ return pulumi.get(self, "transfer_lock_enabled")
157
+
158
+ @transfer_lock_enabled.setter
159
+ def transfer_lock_enabled(self, value: Optional[pulumi.Input[bool]]):
160
+ pulumi.set(self, "transfer_lock_enabled", value)
161
+
162
+ @property
163
+ @pulumi.getter(name="whoisPrivacyEnabled")
164
+ def whois_privacy_enabled(self) -> Optional[pulumi.Input[bool]]:
165
+ """
166
+ Whether the domain should have WhoIs privacy enabled (default: `false`)
167
+ """
168
+ return pulumi.get(self, "whois_privacy_enabled")
169
+
170
+ @whois_privacy_enabled.setter
171
+ def whois_privacy_enabled(self, value: Optional[pulumi.Input[bool]]):
172
+ pulumi.set(self, "whois_privacy_enabled", value)
173
+
174
+
175
+ @pulumi.input_type
176
+ class _RegisteredDomainState:
177
+ def __init__(__self__, *,
178
+ account_id: Optional[pulumi.Input[int]] = None,
179
+ auto_renew_enabled: Optional[pulumi.Input[bool]] = None,
180
+ contact_id: Optional[pulumi.Input[int]] = None,
181
+ dnssec_enabled: Optional[pulumi.Input[bool]] = None,
182
+ domain_registration: Optional[pulumi.Input['RegisteredDomainDomainRegistrationArgs']] = None,
183
+ expires_at: Optional[pulumi.Input[str]] = None,
184
+ extended_attributes: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
185
+ name: Optional[pulumi.Input[str]] = None,
186
+ premium_price: Optional[pulumi.Input[str]] = None,
187
+ registrant_change: Optional[pulumi.Input['RegisteredDomainRegistrantChangeArgs']] = None,
188
+ state: Optional[pulumi.Input[str]] = None,
189
+ timeouts: Optional[pulumi.Input['RegisteredDomainTimeoutsArgs']] = None,
190
+ transfer_lock_enabled: Optional[pulumi.Input[bool]] = None,
191
+ unicode_name: Optional[pulumi.Input[str]] = None,
192
+ whois_privacy_enabled: Optional[pulumi.Input[bool]] = None):
193
+ """
194
+ Input properties used for looking up and filtering RegisteredDomain resources.
195
+ :param pulumi.Input[bool] auto_renew_enabled: Whether the domain should be set to auto-renew (default: `false`)
196
+ :param pulumi.Input[int] contact_id: The ID of the contact to be used for the domain registration. The contact ID can be changed after the domain has been registered. The change will result in a new registrant change this may result in a [60-day lock](https://support.dnsimple.com/articles/icann-60-day-lock-registrant-change/).
197
+ :param pulumi.Input[bool] dnssec_enabled: Whether the domain should have DNSSEC enabled (default: `false`)
198
+ :param pulumi.Input['RegisteredDomainDomainRegistrationArgs'] domain_registration: The domain registration details. (see below for nested schema)
199
+
200
+ <a id="nestedblock--timeouts"></a>
201
+ :param pulumi.Input[Mapping[str, pulumi.Input[str]]] extended_attributes: A map of extended attributes to be set for the domain registration. To see if there are any required extended attributes for any TLD use our [Lists the TLD Extended Attributes API](https://developer.dnsimple.com/v2/tlds/#getTldExtendedAttributes). The values provided in the `extended_attributes` will also be sent when a registrant change is initiated as part of changing the `contact_id`.
202
+ :param pulumi.Input[str] name: The domain name to be registered
203
+ :param pulumi.Input[str] premium_price: The premium price for the domain registration. This is only required if the domain is a premium domain. You can use our [Check domain API](https://developer.dnsimple.com/v2/registrar/#checkDomain) to check if a domain is premium. And [Retrieve domain prices API](https://developer.dnsimple.com/v2/registrar/#getDomainPrices) to retrieve the premium price for a domain.
204
+ :param pulumi.Input['RegisteredDomainRegistrantChangeArgs'] registrant_change: The registrant change details.
205
+ :param pulumi.Input[str] state: The state of the domain.
206
+ :param pulumi.Input['RegisteredDomainTimeoutsArgs'] timeouts: (see below for nested schema)
207
+
208
+ # Attributes Reference
209
+ :param pulumi.Input[bool] transfer_lock_enabled: Whether the domain transfer lock protection is enabled (default: `true`)
210
+ :param pulumi.Input[str] unicode_name: The domain name in Unicode format.
211
+ :param pulumi.Input[bool] whois_privacy_enabled: Whether the domain should have WhoIs privacy enabled (default: `false`)
212
+ """
213
+ if account_id is not None:
214
+ pulumi.set(__self__, "account_id", account_id)
215
+ if auto_renew_enabled is not None:
216
+ pulumi.set(__self__, "auto_renew_enabled", auto_renew_enabled)
217
+ if contact_id is not None:
218
+ pulumi.set(__self__, "contact_id", contact_id)
219
+ if dnssec_enabled is not None:
220
+ pulumi.set(__self__, "dnssec_enabled", dnssec_enabled)
221
+ if domain_registration is not None:
222
+ pulumi.set(__self__, "domain_registration", domain_registration)
223
+ if expires_at is not None:
224
+ pulumi.set(__self__, "expires_at", expires_at)
225
+ if extended_attributes is not None:
226
+ pulumi.set(__self__, "extended_attributes", extended_attributes)
227
+ if name is not None:
228
+ pulumi.set(__self__, "name", name)
229
+ if premium_price is not None:
230
+ pulumi.set(__self__, "premium_price", premium_price)
231
+ if registrant_change is not None:
232
+ pulumi.set(__self__, "registrant_change", registrant_change)
233
+ if state is not None:
234
+ pulumi.set(__self__, "state", state)
235
+ if timeouts is not None:
236
+ pulumi.set(__self__, "timeouts", timeouts)
237
+ if transfer_lock_enabled is not None:
238
+ pulumi.set(__self__, "transfer_lock_enabled", transfer_lock_enabled)
239
+ if unicode_name is not None:
240
+ pulumi.set(__self__, "unicode_name", unicode_name)
241
+ if whois_privacy_enabled is not None:
242
+ pulumi.set(__self__, "whois_privacy_enabled", whois_privacy_enabled)
243
+
244
+ @property
245
+ @pulumi.getter(name="accountId")
246
+ def account_id(self) -> Optional[pulumi.Input[int]]:
247
+ return pulumi.get(self, "account_id")
248
+
249
+ @account_id.setter
250
+ def account_id(self, value: Optional[pulumi.Input[int]]):
251
+ pulumi.set(self, "account_id", value)
252
+
253
+ @property
254
+ @pulumi.getter(name="autoRenewEnabled")
255
+ def auto_renew_enabled(self) -> Optional[pulumi.Input[bool]]:
256
+ """
257
+ Whether the domain should be set to auto-renew (default: `false`)
258
+ """
259
+ return pulumi.get(self, "auto_renew_enabled")
260
+
261
+ @auto_renew_enabled.setter
262
+ def auto_renew_enabled(self, value: Optional[pulumi.Input[bool]]):
263
+ pulumi.set(self, "auto_renew_enabled", value)
264
+
265
+ @property
266
+ @pulumi.getter(name="contactId")
267
+ def contact_id(self) -> Optional[pulumi.Input[int]]:
268
+ """
269
+ The ID of the contact to be used for the domain registration. The contact ID can be changed after the domain has been registered. The change will result in a new registrant change this may result in a [60-day lock](https://support.dnsimple.com/articles/icann-60-day-lock-registrant-change/).
270
+ """
271
+ return pulumi.get(self, "contact_id")
272
+
273
+ @contact_id.setter
274
+ def contact_id(self, value: Optional[pulumi.Input[int]]):
275
+ pulumi.set(self, "contact_id", value)
276
+
277
+ @property
278
+ @pulumi.getter(name="dnssecEnabled")
279
+ def dnssec_enabled(self) -> Optional[pulumi.Input[bool]]:
280
+ """
281
+ Whether the domain should have DNSSEC enabled (default: `false`)
282
+ """
283
+ return pulumi.get(self, "dnssec_enabled")
284
+
285
+ @dnssec_enabled.setter
286
+ def dnssec_enabled(self, value: Optional[pulumi.Input[bool]]):
287
+ pulumi.set(self, "dnssec_enabled", value)
288
+
289
+ @property
290
+ @pulumi.getter(name="domainRegistration")
291
+ def domain_registration(self) -> Optional[pulumi.Input['RegisteredDomainDomainRegistrationArgs']]:
292
+ """
293
+ The domain registration details. (see below for nested schema)
294
+
295
+ <a id="nestedblock--timeouts"></a>
296
+ """
297
+ return pulumi.get(self, "domain_registration")
298
+
299
+ @domain_registration.setter
300
+ def domain_registration(self, value: Optional[pulumi.Input['RegisteredDomainDomainRegistrationArgs']]):
301
+ pulumi.set(self, "domain_registration", value)
302
+
303
+ @property
304
+ @pulumi.getter(name="expiresAt")
305
+ def expires_at(self) -> Optional[pulumi.Input[str]]:
306
+ return pulumi.get(self, "expires_at")
307
+
308
+ @expires_at.setter
309
+ def expires_at(self, value: Optional[pulumi.Input[str]]):
310
+ pulumi.set(self, "expires_at", value)
311
+
312
+ @property
313
+ @pulumi.getter(name="extendedAttributes")
314
+ def extended_attributes(self) -> Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]]:
315
+ """
316
+ A map of extended attributes to be set for the domain registration. To see if there are any required extended attributes for any TLD use our [Lists the TLD Extended Attributes API](https://developer.dnsimple.com/v2/tlds/#getTldExtendedAttributes). The values provided in the `extended_attributes` will also be sent when a registrant change is initiated as part of changing the `contact_id`.
317
+ """
318
+ return pulumi.get(self, "extended_attributes")
319
+
320
+ @extended_attributes.setter
321
+ def extended_attributes(self, value: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]]):
322
+ pulumi.set(self, "extended_attributes", value)
323
+
324
+ @property
325
+ @pulumi.getter
326
+ def name(self) -> Optional[pulumi.Input[str]]:
327
+ """
328
+ The domain name to be registered
329
+ """
330
+ return pulumi.get(self, "name")
331
+
332
+ @name.setter
333
+ def name(self, value: Optional[pulumi.Input[str]]):
334
+ pulumi.set(self, "name", value)
335
+
336
+ @property
337
+ @pulumi.getter(name="premiumPrice")
338
+ def premium_price(self) -> Optional[pulumi.Input[str]]:
339
+ """
340
+ The premium price for the domain registration. This is only required if the domain is a premium domain. You can use our [Check domain API](https://developer.dnsimple.com/v2/registrar/#checkDomain) to check if a domain is premium. And [Retrieve domain prices API](https://developer.dnsimple.com/v2/registrar/#getDomainPrices) to retrieve the premium price for a domain.
341
+ """
342
+ return pulumi.get(self, "premium_price")
343
+
344
+ @premium_price.setter
345
+ def premium_price(self, value: Optional[pulumi.Input[str]]):
346
+ pulumi.set(self, "premium_price", value)
347
+
348
+ @property
349
+ @pulumi.getter(name="registrantChange")
350
+ def registrant_change(self) -> Optional[pulumi.Input['RegisteredDomainRegistrantChangeArgs']]:
351
+ """
352
+ The registrant change details.
353
+ """
354
+ return pulumi.get(self, "registrant_change")
355
+
356
+ @registrant_change.setter
357
+ def registrant_change(self, value: Optional[pulumi.Input['RegisteredDomainRegistrantChangeArgs']]):
358
+ pulumi.set(self, "registrant_change", value)
359
+
360
+ @property
361
+ @pulumi.getter
362
+ def state(self) -> Optional[pulumi.Input[str]]:
363
+ """
364
+ The state of the domain.
365
+ """
366
+ return pulumi.get(self, "state")
367
+
368
+ @state.setter
369
+ def state(self, value: Optional[pulumi.Input[str]]):
370
+ pulumi.set(self, "state", value)
371
+
372
+ @property
373
+ @pulumi.getter
374
+ def timeouts(self) -> Optional[pulumi.Input['RegisteredDomainTimeoutsArgs']]:
375
+ """
376
+ (see below for nested schema)
377
+
378
+ # Attributes Reference
379
+ """
380
+ return pulumi.get(self, "timeouts")
381
+
382
+ @timeouts.setter
383
+ def timeouts(self, value: Optional[pulumi.Input['RegisteredDomainTimeoutsArgs']]):
384
+ pulumi.set(self, "timeouts", value)
385
+
386
+ @property
387
+ @pulumi.getter(name="transferLockEnabled")
388
+ def transfer_lock_enabled(self) -> Optional[pulumi.Input[bool]]:
389
+ """
390
+ Whether the domain transfer lock protection is enabled (default: `true`)
391
+ """
392
+ return pulumi.get(self, "transfer_lock_enabled")
393
+
394
+ @transfer_lock_enabled.setter
395
+ def transfer_lock_enabled(self, value: Optional[pulumi.Input[bool]]):
396
+ pulumi.set(self, "transfer_lock_enabled", value)
397
+
398
+ @property
399
+ @pulumi.getter(name="unicodeName")
400
+ def unicode_name(self) -> Optional[pulumi.Input[str]]:
401
+ """
402
+ The domain name in Unicode format.
403
+ """
404
+ return pulumi.get(self, "unicode_name")
405
+
406
+ @unicode_name.setter
407
+ def unicode_name(self, value: Optional[pulumi.Input[str]]):
408
+ pulumi.set(self, "unicode_name", value)
409
+
410
+ @property
411
+ @pulumi.getter(name="whoisPrivacyEnabled")
412
+ def whois_privacy_enabled(self) -> Optional[pulumi.Input[bool]]:
413
+ """
414
+ Whether the domain should have WhoIs privacy enabled (default: `false`)
415
+ """
416
+ return pulumi.get(self, "whois_privacy_enabled")
417
+
418
+ @whois_privacy_enabled.setter
419
+ def whois_privacy_enabled(self, value: Optional[pulumi.Input[bool]]):
420
+ pulumi.set(self, "whois_privacy_enabled", value)
421
+
422
+
423
+ class RegisteredDomain(pulumi.CustomResource):
424
+ @overload
425
+ def __init__(__self__,
426
+ resource_name: str,
427
+ opts: Optional[pulumi.ResourceOptions] = None,
428
+ auto_renew_enabled: Optional[pulumi.Input[bool]] = None,
429
+ contact_id: Optional[pulumi.Input[int]] = None,
430
+ dnssec_enabled: Optional[pulumi.Input[bool]] = None,
431
+ extended_attributes: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
432
+ name: Optional[pulumi.Input[str]] = None,
433
+ premium_price: Optional[pulumi.Input[str]] = None,
434
+ timeouts: Optional[pulumi.Input[Union['RegisteredDomainTimeoutsArgs', 'RegisteredDomainTimeoutsArgsDict']]] = None,
435
+ transfer_lock_enabled: Optional[pulumi.Input[bool]] = None,
436
+ whois_privacy_enabled: Optional[pulumi.Input[bool]] = None,
437
+ __props__=None):
438
+ """
439
+ Provides a DNSimple registered domain resource.
440
+
441
+ ## Example Usage
442
+
443
+ ```python
444
+ import pulumi
445
+ import pulumi_dnsimple as dnsimple
446
+
447
+ alice_main = dnsimple.Contact("alice_main",
448
+ label="Alice Appleseed",
449
+ first_name="Alice Main",
450
+ last_name="Appleseed",
451
+ organization_name="Contoso",
452
+ job_title="Manager",
453
+ address1="Level 1, 2 Main St",
454
+ address2="Marsfield",
455
+ city="San Francisco",
456
+ state_province="California",
457
+ postal_code="90210",
458
+ country="US",
459
+ phone="+1401239523",
460
+ fax="+1849491024",
461
+ email="apple@contoso.com")
462
+ appleseed_bio = dnsimple.RegisteredDomain("appleseed_bio",
463
+ name="appleseed.bio",
464
+ contact_id=alice_main.id,
465
+ auto_renew_enabled=True,
466
+ transfer_lock_enabled=True,
467
+ whois_privacy_enabled=True,
468
+ dnssec_enabled=False,
469
+ extended_attributes={
470
+ "bio_agree": "I Agree",
471
+ })
472
+ ```
473
+
474
+ ## Import
475
+
476
+ DNSimple registered domains can be imported using their domain name and **optionally** with domain registration ID.
477
+
478
+ **Importing registered domain example.com**
479
+
480
+ bash
481
+
482
+ ```sh
483
+ $ pulumi import dnsimple:index/registeredDomain:RegisteredDomain resource_name example.com
484
+ ```
485
+
486
+ **Importing registered domain example.com with domain registration ID 1234**
487
+
488
+ bash
489
+
490
+ ```sh
491
+ $ pulumi import dnsimple:index/registeredDomain:RegisteredDomain resource_name example.com_1234
492
+ ```
493
+
494
+ :param str resource_name: The name of the resource.
495
+ :param pulumi.ResourceOptions opts: Options for the resource.
496
+ :param pulumi.Input[bool] auto_renew_enabled: Whether the domain should be set to auto-renew (default: `false`)
497
+ :param pulumi.Input[int] contact_id: The ID of the contact to be used for the domain registration. The contact ID can be changed after the domain has been registered. The change will result in a new registrant change this may result in a [60-day lock](https://support.dnsimple.com/articles/icann-60-day-lock-registrant-change/).
498
+ :param pulumi.Input[bool] dnssec_enabled: Whether the domain should have DNSSEC enabled (default: `false`)
499
+ :param pulumi.Input[Mapping[str, pulumi.Input[str]]] extended_attributes: A map of extended attributes to be set for the domain registration. To see if there are any required extended attributes for any TLD use our [Lists the TLD Extended Attributes API](https://developer.dnsimple.com/v2/tlds/#getTldExtendedAttributes). The values provided in the `extended_attributes` will also be sent when a registrant change is initiated as part of changing the `contact_id`.
500
+ :param pulumi.Input[str] name: The domain name to be registered
501
+ :param pulumi.Input[str] premium_price: The premium price for the domain registration. This is only required if the domain is a premium domain. You can use our [Check domain API](https://developer.dnsimple.com/v2/registrar/#checkDomain) to check if a domain is premium. And [Retrieve domain prices API](https://developer.dnsimple.com/v2/registrar/#getDomainPrices) to retrieve the premium price for a domain.
502
+ :param pulumi.Input[Union['RegisteredDomainTimeoutsArgs', 'RegisteredDomainTimeoutsArgsDict']] timeouts: (see below for nested schema)
503
+
504
+ # Attributes Reference
505
+ :param pulumi.Input[bool] transfer_lock_enabled: Whether the domain transfer lock protection is enabled (default: `true`)
506
+ :param pulumi.Input[bool] whois_privacy_enabled: Whether the domain should have WhoIs privacy enabled (default: `false`)
507
+ """
508
+ ...
509
+ @overload
510
+ def __init__(__self__,
511
+ resource_name: str,
512
+ args: RegisteredDomainArgs,
513
+ opts: Optional[pulumi.ResourceOptions] = None):
514
+ """
515
+ Provides a DNSimple registered domain resource.
516
+
517
+ ## Example Usage
518
+
519
+ ```python
520
+ import pulumi
521
+ import pulumi_dnsimple as dnsimple
522
+
523
+ alice_main = dnsimple.Contact("alice_main",
524
+ label="Alice Appleseed",
525
+ first_name="Alice Main",
526
+ last_name="Appleseed",
527
+ organization_name="Contoso",
528
+ job_title="Manager",
529
+ address1="Level 1, 2 Main St",
530
+ address2="Marsfield",
531
+ city="San Francisco",
532
+ state_province="California",
533
+ postal_code="90210",
534
+ country="US",
535
+ phone="+1401239523",
536
+ fax="+1849491024",
537
+ email="apple@contoso.com")
538
+ appleseed_bio = dnsimple.RegisteredDomain("appleseed_bio",
539
+ name="appleseed.bio",
540
+ contact_id=alice_main.id,
541
+ auto_renew_enabled=True,
542
+ transfer_lock_enabled=True,
543
+ whois_privacy_enabled=True,
544
+ dnssec_enabled=False,
545
+ extended_attributes={
546
+ "bio_agree": "I Agree",
547
+ })
548
+ ```
549
+
550
+ ## Import
551
+
552
+ DNSimple registered domains can be imported using their domain name and **optionally** with domain registration ID.
553
+
554
+ **Importing registered domain example.com**
555
+
556
+ bash
557
+
558
+ ```sh
559
+ $ pulumi import dnsimple:index/registeredDomain:RegisteredDomain resource_name example.com
560
+ ```
561
+
562
+ **Importing registered domain example.com with domain registration ID 1234**
563
+
564
+ bash
565
+
566
+ ```sh
567
+ $ pulumi import dnsimple:index/registeredDomain:RegisteredDomain resource_name example.com_1234
568
+ ```
569
+
570
+ :param str resource_name: The name of the resource.
571
+ :param RegisteredDomainArgs args: The arguments to use to populate this resource's properties.
572
+ :param pulumi.ResourceOptions opts: Options for the resource.
573
+ """
574
+ ...
575
+ def __init__(__self__, resource_name: str, *args, **kwargs):
576
+ resource_args, opts = _utilities.get_resource_args_opts(RegisteredDomainArgs, pulumi.ResourceOptions, *args, **kwargs)
577
+ if resource_args is not None:
578
+ __self__._internal_init(resource_name, opts, **resource_args.__dict__)
579
+ else:
580
+ __self__._internal_init(resource_name, *args, **kwargs)
581
+
582
+ def _internal_init(__self__,
583
+ resource_name: str,
584
+ opts: Optional[pulumi.ResourceOptions] = None,
585
+ auto_renew_enabled: Optional[pulumi.Input[bool]] = None,
586
+ contact_id: Optional[pulumi.Input[int]] = None,
587
+ dnssec_enabled: Optional[pulumi.Input[bool]] = None,
588
+ extended_attributes: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
589
+ name: Optional[pulumi.Input[str]] = None,
590
+ premium_price: Optional[pulumi.Input[str]] = None,
591
+ timeouts: Optional[pulumi.Input[Union['RegisteredDomainTimeoutsArgs', 'RegisteredDomainTimeoutsArgsDict']]] = None,
592
+ transfer_lock_enabled: Optional[pulumi.Input[bool]] = None,
593
+ whois_privacy_enabled: Optional[pulumi.Input[bool]] = None,
594
+ __props__=None):
595
+ opts = pulumi.ResourceOptions.merge(_utilities.get_resource_opts_defaults(), opts)
596
+ if not isinstance(opts, pulumi.ResourceOptions):
597
+ raise TypeError('Expected resource options to be a ResourceOptions instance')
598
+ if opts.id is None:
599
+ if __props__ is not None:
600
+ raise TypeError('__props__ is only valid when passed in combination with a valid opts.id to get an existing resource')
601
+ __props__ = RegisteredDomainArgs.__new__(RegisteredDomainArgs)
602
+
603
+ __props__.__dict__["auto_renew_enabled"] = auto_renew_enabled
604
+ if contact_id is None and not opts.urn:
605
+ raise TypeError("Missing required property 'contact_id'")
606
+ __props__.__dict__["contact_id"] = contact_id
607
+ __props__.__dict__["dnssec_enabled"] = dnssec_enabled
608
+ __props__.__dict__["extended_attributes"] = extended_attributes
609
+ if name is None and not opts.urn:
610
+ raise TypeError("Missing required property 'name'")
611
+ __props__.__dict__["name"] = name
612
+ __props__.__dict__["premium_price"] = premium_price
613
+ __props__.__dict__["timeouts"] = timeouts
614
+ __props__.__dict__["transfer_lock_enabled"] = transfer_lock_enabled
615
+ __props__.__dict__["whois_privacy_enabled"] = whois_privacy_enabled
616
+ __props__.__dict__["account_id"] = None
617
+ __props__.__dict__["domain_registration"] = None
618
+ __props__.__dict__["expires_at"] = None
619
+ __props__.__dict__["registrant_change"] = None
620
+ __props__.__dict__["state"] = None
621
+ __props__.__dict__["unicode_name"] = None
622
+ super(RegisteredDomain, __self__).__init__(
623
+ 'dnsimple:index/registeredDomain:RegisteredDomain',
624
+ resource_name,
625
+ __props__,
626
+ opts)
627
+
628
+ @staticmethod
629
+ def get(resource_name: str,
630
+ id: pulumi.Input[str],
631
+ opts: Optional[pulumi.ResourceOptions] = None,
632
+ account_id: Optional[pulumi.Input[int]] = None,
633
+ auto_renew_enabled: Optional[pulumi.Input[bool]] = None,
634
+ contact_id: Optional[pulumi.Input[int]] = None,
635
+ dnssec_enabled: Optional[pulumi.Input[bool]] = None,
636
+ domain_registration: Optional[pulumi.Input[Union['RegisteredDomainDomainRegistrationArgs', 'RegisteredDomainDomainRegistrationArgsDict']]] = None,
637
+ expires_at: Optional[pulumi.Input[str]] = None,
638
+ extended_attributes: Optional[pulumi.Input[Mapping[str, pulumi.Input[str]]]] = None,
639
+ name: Optional[pulumi.Input[str]] = None,
640
+ premium_price: Optional[pulumi.Input[str]] = None,
641
+ registrant_change: Optional[pulumi.Input[Union['RegisteredDomainRegistrantChangeArgs', 'RegisteredDomainRegistrantChangeArgsDict']]] = None,
642
+ state: Optional[pulumi.Input[str]] = None,
643
+ timeouts: Optional[pulumi.Input[Union['RegisteredDomainTimeoutsArgs', 'RegisteredDomainTimeoutsArgsDict']]] = None,
644
+ transfer_lock_enabled: Optional[pulumi.Input[bool]] = None,
645
+ unicode_name: Optional[pulumi.Input[str]] = None,
646
+ whois_privacy_enabled: Optional[pulumi.Input[bool]] = None) -> 'RegisteredDomain':
647
+ """
648
+ Get an existing RegisteredDomain resource's state with the given name, id, and optional extra
649
+ properties used to qualify the lookup.
650
+
651
+ :param str resource_name: The unique name of the resulting resource.
652
+ :param pulumi.Input[str] id: The unique provider ID of the resource to lookup.
653
+ :param pulumi.ResourceOptions opts: Options for the resource.
654
+ :param pulumi.Input[bool] auto_renew_enabled: Whether the domain should be set to auto-renew (default: `false`)
655
+ :param pulumi.Input[int] contact_id: The ID of the contact to be used for the domain registration. The contact ID can be changed after the domain has been registered. The change will result in a new registrant change this may result in a [60-day lock](https://support.dnsimple.com/articles/icann-60-day-lock-registrant-change/).
656
+ :param pulumi.Input[bool] dnssec_enabled: Whether the domain should have DNSSEC enabled (default: `false`)
657
+ :param pulumi.Input[Union['RegisteredDomainDomainRegistrationArgs', 'RegisteredDomainDomainRegistrationArgsDict']] domain_registration: The domain registration details. (see below for nested schema)
658
+
659
+ <a id="nestedblock--timeouts"></a>
660
+ :param pulumi.Input[Mapping[str, pulumi.Input[str]]] extended_attributes: A map of extended attributes to be set for the domain registration. To see if there are any required extended attributes for any TLD use our [Lists the TLD Extended Attributes API](https://developer.dnsimple.com/v2/tlds/#getTldExtendedAttributes). The values provided in the `extended_attributes` will also be sent when a registrant change is initiated as part of changing the `contact_id`.
661
+ :param pulumi.Input[str] name: The domain name to be registered
662
+ :param pulumi.Input[str] premium_price: The premium price for the domain registration. This is only required if the domain is a premium domain. You can use our [Check domain API](https://developer.dnsimple.com/v2/registrar/#checkDomain) to check if a domain is premium. And [Retrieve domain prices API](https://developer.dnsimple.com/v2/registrar/#getDomainPrices) to retrieve the premium price for a domain.
663
+ :param pulumi.Input[Union['RegisteredDomainRegistrantChangeArgs', 'RegisteredDomainRegistrantChangeArgsDict']] registrant_change: The registrant change details.
664
+ :param pulumi.Input[str] state: The state of the domain.
665
+ :param pulumi.Input[Union['RegisteredDomainTimeoutsArgs', 'RegisteredDomainTimeoutsArgsDict']] timeouts: (see below for nested schema)
666
+
667
+ # Attributes Reference
668
+ :param pulumi.Input[bool] transfer_lock_enabled: Whether the domain transfer lock protection is enabled (default: `true`)
669
+ :param pulumi.Input[str] unicode_name: The domain name in Unicode format.
670
+ :param pulumi.Input[bool] whois_privacy_enabled: Whether the domain should have WhoIs privacy enabled (default: `false`)
671
+ """
672
+ opts = pulumi.ResourceOptions.merge(opts, pulumi.ResourceOptions(id=id))
673
+
674
+ __props__ = _RegisteredDomainState.__new__(_RegisteredDomainState)
675
+
676
+ __props__.__dict__["account_id"] = account_id
677
+ __props__.__dict__["auto_renew_enabled"] = auto_renew_enabled
678
+ __props__.__dict__["contact_id"] = contact_id
679
+ __props__.__dict__["dnssec_enabled"] = dnssec_enabled
680
+ __props__.__dict__["domain_registration"] = domain_registration
681
+ __props__.__dict__["expires_at"] = expires_at
682
+ __props__.__dict__["extended_attributes"] = extended_attributes
683
+ __props__.__dict__["name"] = name
684
+ __props__.__dict__["premium_price"] = premium_price
685
+ __props__.__dict__["registrant_change"] = registrant_change
686
+ __props__.__dict__["state"] = state
687
+ __props__.__dict__["timeouts"] = timeouts
688
+ __props__.__dict__["transfer_lock_enabled"] = transfer_lock_enabled
689
+ __props__.__dict__["unicode_name"] = unicode_name
690
+ __props__.__dict__["whois_privacy_enabled"] = whois_privacy_enabled
691
+ return RegisteredDomain(resource_name, opts=opts, __props__=__props__)
692
+
693
+ @property
694
+ @pulumi.getter(name="accountId")
695
+ def account_id(self) -> pulumi.Output[int]:
696
+ return pulumi.get(self, "account_id")
697
+
698
+ @property
699
+ @pulumi.getter(name="autoRenewEnabled")
700
+ def auto_renew_enabled(self) -> pulumi.Output[bool]:
701
+ """
702
+ Whether the domain should be set to auto-renew (default: `false`)
703
+ """
704
+ return pulumi.get(self, "auto_renew_enabled")
705
+
706
+ @property
707
+ @pulumi.getter(name="contactId")
708
+ def contact_id(self) -> pulumi.Output[int]:
709
+ """
710
+ The ID of the contact to be used for the domain registration. The contact ID can be changed after the domain has been registered. The change will result in a new registrant change this may result in a [60-day lock](https://support.dnsimple.com/articles/icann-60-day-lock-registrant-change/).
711
+ """
712
+ return pulumi.get(self, "contact_id")
713
+
714
+ @property
715
+ @pulumi.getter(name="dnssecEnabled")
716
+ def dnssec_enabled(self) -> pulumi.Output[bool]:
717
+ """
718
+ Whether the domain should have DNSSEC enabled (default: `false`)
719
+ """
720
+ return pulumi.get(self, "dnssec_enabled")
721
+
722
+ @property
723
+ @pulumi.getter(name="domainRegistration")
724
+ def domain_registration(self) -> pulumi.Output['outputs.RegisteredDomainDomainRegistration']:
725
+ """
726
+ The domain registration details. (see below for nested schema)
727
+
728
+ <a id="nestedblock--timeouts"></a>
729
+ """
730
+ return pulumi.get(self, "domain_registration")
731
+
732
+ @property
733
+ @pulumi.getter(name="expiresAt")
734
+ def expires_at(self) -> pulumi.Output[str]:
735
+ return pulumi.get(self, "expires_at")
736
+
737
+ @property
738
+ @pulumi.getter(name="extendedAttributes")
739
+ def extended_attributes(self) -> pulumi.Output[Optional[Mapping[str, str]]]:
740
+ """
741
+ A map of extended attributes to be set for the domain registration. To see if there are any required extended attributes for any TLD use our [Lists the TLD Extended Attributes API](https://developer.dnsimple.com/v2/tlds/#getTldExtendedAttributes). The values provided in the `extended_attributes` will also be sent when a registrant change is initiated as part of changing the `contact_id`.
742
+ """
743
+ return pulumi.get(self, "extended_attributes")
744
+
745
+ @property
746
+ @pulumi.getter
747
+ def name(self) -> pulumi.Output[str]:
748
+ """
749
+ The domain name to be registered
750
+ """
751
+ return pulumi.get(self, "name")
752
+
753
+ @property
754
+ @pulumi.getter(name="premiumPrice")
755
+ def premium_price(self) -> pulumi.Output[Optional[str]]:
756
+ """
757
+ The premium price for the domain registration. This is only required if the domain is a premium domain. You can use our [Check domain API](https://developer.dnsimple.com/v2/registrar/#checkDomain) to check if a domain is premium. And [Retrieve domain prices API](https://developer.dnsimple.com/v2/registrar/#getDomainPrices) to retrieve the premium price for a domain.
758
+ """
759
+ return pulumi.get(self, "premium_price")
760
+
761
+ @property
762
+ @pulumi.getter(name="registrantChange")
763
+ def registrant_change(self) -> pulumi.Output['outputs.RegisteredDomainRegistrantChange']:
764
+ """
765
+ The registrant change details.
766
+ """
767
+ return pulumi.get(self, "registrant_change")
768
+
769
+ @property
770
+ @pulumi.getter
771
+ def state(self) -> pulumi.Output[str]:
772
+ """
773
+ The state of the domain.
774
+ """
775
+ return pulumi.get(self, "state")
776
+
777
+ @property
778
+ @pulumi.getter
779
+ def timeouts(self) -> pulumi.Output[Optional['outputs.RegisteredDomainTimeouts']]:
780
+ """
781
+ (see below for nested schema)
782
+
783
+ # Attributes Reference
784
+ """
785
+ return pulumi.get(self, "timeouts")
786
+
787
+ @property
788
+ @pulumi.getter(name="transferLockEnabled")
789
+ def transfer_lock_enabled(self) -> pulumi.Output[bool]:
790
+ """
791
+ Whether the domain transfer lock protection is enabled (default: `true`)
792
+ """
793
+ return pulumi.get(self, "transfer_lock_enabled")
794
+
795
+ @property
796
+ @pulumi.getter(name="unicodeName")
797
+ def unicode_name(self) -> pulumi.Output[str]:
798
+ """
799
+ The domain name in Unicode format.
800
+ """
801
+ return pulumi.get(self, "unicode_name")
802
+
803
+ @property
804
+ @pulumi.getter(name="whoisPrivacyEnabled")
805
+ def whois_privacy_enabled(self) -> pulumi.Output[bool]:
806
+ """
807
+ Whether the domain should have WhoIs privacy enabled (default: `false`)
808
+ """
809
+ return pulumi.get(self, "whois_privacy_enabled")
810
+