Skip to content

Commit 6b26150

Browse files
committed
fix: Add CAA record type to DNS enum classes to support custom domain operations
This commit resolves a critical validation error that caused 5 out of 6 custom domain API endpoints to fail when the Okta API returned CAA (Certificate Authority Authorization) DNS records. Problem: - DNSRecordTypeDomains and EmailDomainDNSRecordType enums only defined CNAME and TXT - When API returned CAA records, Pydantic validation failed during deserialization Solution: Added CAA record type to both enum classes: - okta/models/dns_record_type_domains.py - okta/models/email_domain_dns_record_type.py Testing: Verified with get_custom_domain() method that CAA records now deserialize correctly without validation errors.
1 parent 67846b4 commit 6b26150

3 files changed

Lines changed: 4 additions & 0 deletions

File tree

okta/models/dns_record_type_domains.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ class DNSRecordTypeDomains(str, Enum):
3838
"""
3939
CNAME = "CNAME"
4040
TXT = "TXT"
41+
CAA = "CAA"
4142

4243
@classmethod
4344
def from_json(cls, json_str: str) -> Self:

okta/models/email_domain_dns_record_type.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ class EmailDomainDNSRecordType(str, Enum):
3838
"""
3939
CNAME = "CNAME"
4040
TXT = "TXT"
41+
CAA = "CAA"
4142

4243
@classmethod
4344
def from_json(cls, json_str: str) -> Self:

openapi/api.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63370,6 +63370,7 @@ components:
6337063370
enum:
6337163371
- CNAME
6337263372
- TXT
63373+
- CAA
6337363374
DRStatusItem:
6337463375
description: Status whether a domain has been failed over or not
6337563376
type: object
@@ -64698,6 +64699,7 @@ components:
6469864699
enum:
6469964700
- CNAME
6470064701
- TXT
64702+
- CAA
6470164703
EmailDomainResponse:
6470264704
allOf:
6470364705
- $ref: '#/components/schemas/BaseEmailDomain'

0 commit comments

Comments
 (0)